Tag Info

New answers tagged


Attempt to fetch the user record based on the username (but use LIKE instead of = so that case doesn't matter. Usernames should not be case sensitive. If you managed to fetch a user record (then the user exists) and you can compare the passwords to validate the login. About password security Store the passwords using a function like password_hash() so ...


Typically I'd just search the table for the record that contains the matching username. If that record doesn't exist the user doesn't exist so there is no need to go any further. If the record does exist that record would have the password hash on it for that user. Take the password given by the user, hash it in the same way, compare to the hash in your ...

Top 50 recent answers are included