diff --git a/wp-register.php b/wp-register.php index 1177c12867..49798c3314 100644 --- a/wp-register.php +++ b/wp-register.php @@ -25,10 +25,13 @@ case 'register': $errors['user_email'] = __('ERROR: Please type your e-mail address.'); } else if (!is_email($user_email)) { $errors['user_email'] = __('ERROR: The email address isn’t correct.'); + $user_email = ''; } - if ( ! validate_username($user_login) ) + if ( ! validate_username($user_login) ) { $errors['user_login'] = __('ERROR: This username is invalid. Please enter a valid username.'); + $user_login = ''; + } if ( username_exists( $user_login ) ) $errors['user_login'] = __('ERROR: This username is already registered, please choose another one.'); @@ -67,9 +70,9 @@ case 'register':
$user_login") ?>
+
" . wp_specialchars($user_login) . "") ?>
' . __('emailed to you') . '') ?>
- $user_email") ?>