simple table with username and password using md5 encryption.
user POPSHUVITS with pword SALERO added to the table. A browse of the table shows pword as 015ed62fe
//Now, in a login script if the user signs in I get the following :
015ed62fe031ad4895b025c92a5a83aa Incorrect password, please try again.
//I am echoing the pword the user puts into the login.php and as you can see it does return the password encrypted correctly 015ed62fe..but it has a bunch of other junk in it
031ad4895b025c92a5a83aa
any clue as to why?
here is the code snippet I am using in the login.php
while($info = mysql_fetch_array( $check ))
{
$_POST['pass'] = stripslashes($_POST['pass']);
$info['mem_pword'] = stripslashes($info['mem_pword']);
$_POST['pass'] = md5($_POST['pass']);
echo $_POST['pass']; //this has the correct pword but other junk..see above
//echo $info['mem_pword']; //echoing the pword from the db shows the md5pword in the db correctly.
//gives error if the password is wrong
if ($_POST['pass'] != $info['mem_pword']) {
die('Incorrect password, please try again.');
}
else
{