Make WordPress Core

Changeset 10960


Ignore:
Timestamp:
04/16/2009 10:07:25 PM (15 years ago)
Author:
ryan
Message:

Add link to password recovery in login error messages. Props Denis-de-Bernardy. fixes #9442

File:
1 edited

Legend:

Unmodified
Added
Removed
  • trunk/wp-includes/user.php

    r10891 r10960  
    8787
    8888    if ( !$userdata || ($userdata->user_login != $username) ) {
    89         return new WP_Error('invalid_username', __('<strong>ERROR</strong>: Invalid username.'));
     89        return new WP_Error('invalid_username', sprintf(__('<strong>ERROR</strong>: Invalid username. <a href="%s" title="Password Lost and Found">Lost your password</a>?'), site_url('wp-login.php?action=lostpassword', 'login')));
    9090    }
    9191
     
    9696
    9797    if ( !wp_check_password($password, $userdata->user_pass, $userdata->ID) ) {
    98         return new WP_Error('incorrect_password', __('<strong>ERROR</strong>: Incorrect password.'));
     98        return new WP_Error('incorrect_password', sprintf(__('<strong>ERROR</strong>: Incorrect password. <a href="%s" title="Password Lost and Found">Lost your password</a>?'), site_url('wp-login.php?action=lostpassword', 'login')));
    9999    }
    100100
Note: See TracChangeset for help on using the changeset viewer.