I am trying to use the lost password function but am getting an error. Following my clicking on the URL link contained in the sent e-mail for resetting the lost password, I am returned to my classified site, but then I get the following error: “There was an error with this operation: This reset link is invalid. Please click back to continue.”
I've tried testing the lost password functionality on the WWC Demo with the same results. Has a solution for this problem already been provided on the support forum?
I will look into it. I havent had a problem with it yet.
Open index.php and find this line:
$link = $site_url . getenv('SCRIPT_NAME') . "?Confirm_Reset&ID=" . $user[1] . $user[2] . "&UID=" . $user[0];
Change to:
$link = $site_url . getenv('SCRIPT_NAME') . "?Confirm_Reset&" . $user[1] . $user[2] . "&" . $user[0];
Find these lines:
$email = Get_User_Email($UID);
if ($email == "") { oops(Messages('InvalidResetLink')); }
$user = Get_User_From_Email($email);
if ($ID != $user[1] . $user[2]) { Update_Salt(time(), $url); oops(Messages('InvalidResetLink')); }
$new_pass = Random_Password(7);
Update_Pass(md5($new_pass),$UID);
$reset_message = preg_replace("/\[USER\]/", Get_User_Name($UID), $reset_message);
REPLACE with these lines:
$email = Get_User_Email($ARGV[2]);
if ($email == "") { oops(Messages('InvalidResetLink')); }
$user = Get_User_From_Email($email);
if ($ARGV[1] != $user[1] . $user[2]) { Update_Salt(time(), $url); oops(Messages('InvalidResetLink')); }
$new_pass = Random_Password(7);
Update_Pass(md5($new_pass),$ARGV[2]);
$reset_message = preg_replace("/\[USER\]/", Get_User_Name($ARGV[2]), $reset_message);
I thought this was already fixed in the release, but I see it was not. This should take care of it.