Modified All Authorization/DB query Scripts

All these scripts now employ mysqli to aid in preventing SQL injections