This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| function login_with_email_address($username) { | |
| $user = get_user_by('email',$username); | |
| if(!empty($user->user_login)) | |
| $username = $user->user_login; | |
| return $username; | |
| } | |
| add_action('wp_authenticate','login_with_email_address'); | |
| function change_username_wps_text($text){ | |
| if(in_array($GLOBALS['pagenow'], array('wp-login.php'))){ |