I am writing a login script for a program of mine. In the environment I was testing I had PHP 4.0.6, but moving to my clients box, I encountered the standard problem , since he had PHP 4.2.3.
Now, my problem was with the MySQL query. The actual problem was with ""s and ' ' s.
My original code was:
Code: Select all
$query = "SELECT * FROM admins WHERE usr='$username' AND pwd='$password'";I know I can change the names of the form objects, so that I don't have to use quotes in the array, but I am sure there's another way.
Thanks in advance,
Xelmepa