Support » Fixing WordPress » How to Change Password Recovery Email Text

  • Uli


    I am trying to change the default text for the password reset email (after somebody has entered their username/email in the password reset field.

    I changed the text in wp-login.php (line 235) from
    $message .= __('To reset your password, visit the following address:') . "\r\n\r\n";
    $message .= __('To reset your password, visit the following URL. Note that AOL and some other email systems disable all links inside emails, so you must manually copy and paste the link below into your web browser address bar. If you do not get a new password within the next 2 minutes, please check your spam or trash folder.') . "\r\n\r\n";

    then uploaded the file to the server. But when I test the password reset anew, it still shows the old message. And yes, I did empty the cache after uploading the file.

Viewing 5 replies - 1 through 5 (of 5 total)
  • esmi


    No! Never, ever, edit WordPress core scripts. And do not encourage others to do so. Editing core scripts can bring down your entire site and/or open security holes for hackers to use. Re-upload a fresh copy of wp-login.php then try amending the message using the retrieve_password_message filter in your theme’s functions.php



    Maybe try some smartkey password recovery methods?
    Use another email address?
    Register with another account?
    Visit ?
    I am not sure.



    I adapted the code here:


    Been trying to find an answer to this for weeks. Existing plugins that do this conflict with my main plugin, so I need more insight into how to “retrieve_password_message filter in your theme’s functions.php” mentioned above.

    Rocio Valdivia


    Thanks for the link Uli, the functions of work great 🙂

    BTW, there is no filters to change the email’s headers to be able to send HTML in the message 🙁

    Right now, the only way is changing the wp-login.php and I don’t want to modify the core, so I’ll make a patch and to open a ticket in the trac.

    I’ll post it here too, maybe is useful for someone else


Viewing 5 replies - 1 through 5 (of 5 total)
  • The topic ‘How to Change Password Recovery Email Text’ is closed to new replies.