Hey all,
I'm using the following code to save an MD5 password into a database along
with an unencrypted username and email address:
$insertSQL = sprintf("INSERT INTO penpals (email, password, username) VALUES
(%s, MD5(%s), %s)",
All seems to have worked well, the password is encrypted and so forth. I
have also attempted to use the following MySQL command to encrypt the
password and came up with the same result:
UPDATE penpals SET password = MD5(password) WHERE ID = 1
So the trouble seems to be with the login where I am using the following
code:
SELECT email, password, access FROM penpals WHERE email= '%s' AND password =
MD5('%s')
Am I missing something here? Am I some how double encrypting the password?
Is there a de-encrypt function or something I'm missing?
Thanks
--
PHP General Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php