Hi all
Im having a problem with this MySQL statement, Im trying to set up a login system following instructions from another site
All is working well except it fails when I try to log in,
Why would this NOT work
$sql = "SELECT * FROM user WHERE userid = '$uid' AND password = PASSWORD('$pwd')";
when this does
$sql = "SELECT * FROM user WHERE userid = '$uid' ";
It would seem this part is not functioning correctly
AND password = PASSWORD('$pwd')
Just for ref this is the insert statement used to create a new user, working ok!
$sql = "INSERT INTO user SET userid = '$_POST[newid]', password = PASSWORD('$newpass'), fullname = '$_POST[newname]', email = '$_POST[newemail]', notes = '$_POST[newnotes]'";
Specs:-
Server: Localhost via UNIX socket
Server type: MySQL
Server version: 5.5.42 - MySQL Community Server (GPL)
Apache/2.4.10 (Unix)
Database client version: libmysql - mysqlnd 5.0.8-dev
PHP extension: mysqli Version information: 4.0.7, latest stable version: 4.4.12
PHP version 5.3