Simple Machines Community Forum

SMF Support => SMF 2.0.x Support => Topic started by: JamesD01 on August 29, 2008, 05:17:06 PM

Title: Password recovery not working, a bug?
Post by: JamesD01 on August 29, 2008, 05:17:06 PM
I am a Administrator of 2 forums, both of which are SMF 2.0 Beta 3.1. they are hosted on different networks. 1 is on Windows and the other is on Linux.

For some odd reason, not sure if its a known bug.. but the password recovery function does not work. It says its sent it, but no email in the inbox. I checked the junk mailbox too.. And yes, i did check the correct email address...

So, is it a known bug, or is it a new one to be fixed on SMF 2.0 Beta 4?

Many thanks in advance to all that replies. :)
Title: Re: Password recovery not working, a bug?
Post by: NickC on August 30, 2008, 10:35:03 AM
It's a bug in the current beta version. The fix is published here:

0001780: Password reminder not working (http://dev.simplemachines.org/mantis/view.php?id=1780)
Title: Re: Password recovery not working, a bug?
Post by: JamesD01 on August 30, 2008, 10:53:23 AM
Ahh, Thanks so much.. :)
Title: Re: Password recovery not working, a bug?
Post by: JamesD01 on August 31, 2008, 10:00:59 AM
When looking in the reminder.php file, I could not find


        if (!empty($row['openid_uri']))
            sendmail($row['email_address'], $emaildata['subject'], $emaildata['body']);
        else
        {
            // Set the password in the database.
            updateMemberData($row['id_member'], array('validation_code' => substr(md5($password), 0, 10)));
        }


So that I could replace it with;

        sendmail($row['email_address'], $emaildata['subject'], $emaildata['body']);
        if (empty($row['openid_uri']))
        {
            // Set the password in the database.
            updateMemberData($row['id_member'], array('validation_code' => substr(md5($password), 0, 10)));
        }


I've attached the reminder.php file to this post..
Title: Re: Password recovery not working, a bug?
Post by: NickC on August 31, 2008, 10:11:09 AM
It's definitely in there, starting at line 164.
Title: Re: Password recovery not working, a bug?
Post by: JamesD01 on August 31, 2008, 10:24:03 AM
Quote from: NickC on August 31, 2008, 10:11:09 AM
It's definitely in there, starting at line 164.
Thanks, I've done the edit.. but still nothing in my inbox..

I've attached the edited reminder.php file
Title: Re: Password recovery not working, a bug?
Post by: NickC on August 31, 2008, 10:39:35 AM
It won't resurrect previous password requests, but new ones should work.
Title: Re: Password recovery not working, a bug?
Post by: JamesD01 on August 31, 2008, 10:41:38 AM
Quote from: NickC on August 31, 2008, 10:39:35 AM
It won't resurrect previous password requests, but new ones should work.
Ahh, Thanks for your help :)

All works now. :)