You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
I have a table called users, and I used to check email adress and password for login credentials. Everything worked fine, but suddenly email addresses stopped working so I removed @ symbol from email and it started working.
Here's my query:
$user = $db->row("SELECT * FROM users WHERE email=:email AND password=:password", array("email"=>$_POST['email'], "password"=> md5($_POST['password']) ));
this returns 0 results if email address has @ symbol.
And returns 1 row if I remove @ sign from email address in database.
How should I solve it?
The text was updated successfully, but these errors were encountered:
Seems this package is not maintained but I had a similar issue with similar symptoms.
The culprit was my database table accepting an integer when my variable was string. I suspect you need to edit the column type. Again, two years late. Hope this helps someone.
I have a table called users, and I used to check email adress and password for login credentials. Everything worked fine, but suddenly email addresses stopped working so I removed @ symbol from email and it started working.
Here's my query:
$user = $db->row("SELECT * FROM
users
WHERE email=:email AND password=:password", array("email"=>$_POST['email'], "password"=> md5($_POST['password']) ));this returns 0 results if email address has @ symbol.
And returns 1 row if I remove @ sign from email address in database.
How should I solve it?
The text was updated successfully, but these errors were encountered: