WordPress.org

Ready to get started?Download WordPress

Forums

How to Change Password Recovery Email Text (6 posts)

  1. Uli
    Member
    Posted 1 year ago #

    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";
    to
    $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.

  2. esmi
    Forum Moderator
    Posted 1 year ago #

    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

  3. Charles89
    Member
    Posted 1 year ago #

    Maybe try some smartkey password recovery methods?
    Use another email address?
    Register with another account?
    Visit http://www.recoverlostpassword.com ?
    I am not sure.

  4. Uli
    Member
    Posted 1 year ago #

    I adapted the code here: http://s14.codeinspot.com/q/2472332

    Thanks.

  5. thevolkman
    Member
    Posted 1 year ago #

    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.

  6. Rocio Valdivia
    Member
    Posted 6 months ago #

    Thanks for the link Uli, the functions of http://s14.codeinspot.com/q/2472332 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

    Cheers!

Topic Closed

This topic has been closed to new replies.

About this Topic