Authorization script written in PHP and MySQL