character conversion -- what function is this??
I'm writing a page as an addition to my forum and I need to have a login on it.
The passwords are encrypted using the md5() function, then stored in the database. To login, it takes the submitted password, then uses the md5() on that and compares it to the stored value in the database. If it's a match, then the passwords were as well. Fairly standard procedure.
I've had success doing this before, but I just ran into trouble when using a password that had a symbol in it.
For testing purposes, I tried using the password:
!@#$%^&*()?abc123
and the result was:
HTML Code:
&`#33;@#&`#036;%^&*()?abc123
(NOTE: ignore the backticks-- ````, between the &/#. If I don't put something in there, the board displays the character (ie-- #33 becomes !, etc.)
What I can't do, however, is match that encoding. All I need to do to verify the password is:
if ($dbpassstored == md5(encodefunction($sentpass))) {}
But I don't know what "encodefunction" is.
So, can someone tell me what I could use to get that result?
I already tried htmlentities() and urlencode(), but the results are different.
Thanks.