diff --git a/wp-admin/includes/file.php b/wp-admin/includes/file.php index a19871aa05..8a178022dc 100644 --- a/wp-admin/includes/file.php +++ b/wp-admin/includes/file.php @@ -2302,7 +2302,7 @@ function request_filesystem_credentials( $form_post, $type = '', $error = false, $connection_type = isset( $credentials['connection_type'] ) ? $credentials['connection_type'] : ''; if ( $error ) { - $error_string = __( 'Error: Could not connect to the server. Please verify the settings are correct.' ); + $error_string = __( 'Error: Could not connect to the server. Please verify the settings are correct.' ); if ( is_wp_error( $error ) ) { $error_string = esc_html( $error->get_error_message() ); } diff --git a/wp-admin/includes/user.php b/wp-admin/includes/user.php index ed6a91a4e2..134da30514 100644 --- a/wp-admin/includes/user.php +++ b/wp-admin/includes/user.php @@ -143,12 +143,12 @@ function edit_user( $user_id = 0 ) { /* checking that username has been typed */ if ( '' === $user->user_login ) { - $errors->add( 'user_login', __( 'Error: Please enter a username.' ) ); + $errors->add( 'user_login', __( 'Error: Please enter a username.' ) ); } /* checking that nickname has been typed */ if ( $update && empty( $user->nickname ) ) { - $errors->add( 'nickname', __( 'Error: Please enter a nickname.' ) ); + $errors->add( 'nickname', __( 'Error: Please enter a nickname.' ) ); } /** @@ -164,17 +164,17 @@ function edit_user( $user_id = 0 ) { // Check for blank password when adding a user. if ( ! $update && empty( $pass1 ) ) { - $errors->add( 'pass', __( 'Error: Please enter a password.' ), array( 'form-field' => 'pass1' ) ); + $errors->add( 'pass', __( 'Error: Please enter a password.' ), array( 'form-field' => 'pass1' ) ); } // Check for "\" in password. if ( false !== strpos( wp_unslash( $pass1 ), '\\' ) ) { - $errors->add( 'pass', __( 'Error: Passwords may not contain the character "\\".' ), array( 'form-field' => 'pass1' ) ); + $errors->add( 'pass', __( 'Error: Passwords may not contain the character "\\".' ), array( 'form-field' => 'pass1' ) ); } // Checking the password has been typed twice the same. if ( ( $update || ! empty( $pass1 ) ) && $pass1 != $pass2 ) { - $errors->add( 'pass', __( 'Error: Passwords do not match. Please enter the same password in both password fields.' ), array( 'form-field' => 'pass1' ) ); + $errors->add( 'pass', __( 'Error: Passwords do not match. Please enter the same password in both password fields.' ), array( 'form-field' => 'pass1' ) ); } if ( ! empty( $pass1 ) ) { @@ -182,29 +182,29 @@ function edit_user( $user_id = 0 ) { } if ( ! $update && isset( $_POST['user_login'] ) && ! validate_username( $_POST['user_login'] ) ) { - $errors->add( 'user_login', __( 'Error: This username is invalid because it uses illegal characters. Please enter a valid username.' ) ); + $errors->add( 'user_login', __( 'Error: This username is invalid because it uses illegal characters. Please enter a valid username.' ) ); } if ( ! $update && username_exists( $user->user_login ) ) { - $errors->add( 'user_login', __( 'Error: This username is already registered. Please choose another one.' ) ); + $errors->add( 'user_login', __( 'Error: This username is already registered. Please choose another one.' ) ); } /** This filter is documented in wp-includes/user.php */ $illegal_logins = (array) apply_filters( 'illegal_user_logins', array() ); if ( in_array( strtolower( $user->user_login ), array_map( 'strtolower', $illegal_logins ), true ) ) { - $errors->add( 'invalid_username', __( 'Error: Sorry, that username is not allowed.' ) ); + $errors->add( 'invalid_username', __( 'Error: Sorry, that username is not allowed.' ) ); } /* checking email address */ if ( empty( $user->user_email ) ) { - $errors->add( 'empty_email', __( 'Error: Please enter an email address.' ), array( 'form-field' => 'email' ) ); + $errors->add( 'empty_email', __( 'Error: Please enter an email address.' ), array( 'form-field' => 'email' ) ); } elseif ( ! is_email( $user->user_email ) ) { - $errors->add( 'invalid_email', __( 'Error: The email address is not correct.' ), array( 'form-field' => 'email' ) ); + $errors->add( 'invalid_email', __( 'Error: The email address is not correct.' ), array( 'form-field' => 'email' ) ); } else { $owner_id = email_exists( $user->user_email ); if ( $owner_id && ( ! $update || ( $owner_id != $user->ID ) ) ) { - $errors->add( 'email_exists', __( 'Error: This email is already registered. Please choose another one.' ), array( 'form-field' => 'email' ) ); + $errors->add( 'email_exists', __( 'Error: This email is already registered. Please choose another one.' ), array( 'form-field' => 'email' ) ); } } diff --git a/wp-admin/setup-config.php b/wp-admin/setup-config.php index 487bdae31d..86c2fbce7f 100644 --- a/wp-admin/setup-config.php +++ b/wp-admin/setup-config.php @@ -278,12 +278,12 @@ switch ( $step ) { $tryagain_link = '
' . __( 'Try Again' ) . '';
if ( empty( $prefix ) ) {
- wp_die( __( 'Error: "Table Prefix" must not be empty.' ) . $tryagain_link );
+ wp_die( __( 'Error: "Table Prefix" must not be empty.' ) . $tryagain_link );
}
// Validate $prefix: it can only contain letters, numbers and underscores.
if ( preg_match( '|[^a-z0-9_]|i', $prefix ) ) {
- wp_die( __( 'Error: "Table Prefix" can only contain numbers, letters, and underscores.' ) . $tryagain_link );
+ wp_die( __( 'Error: "Table Prefix" can only contain numbers, letters, and underscores.' ) . $tryagain_link );
}
// Test the DB connection.
@@ -316,7 +316,7 @@ switch ( $step ) {
$wpdb->show_errors( $errors );
if ( ! $wpdb->last_error ) {
// MySQL was able to parse the prefix as a value, which we don't want. Bail.
- wp_die( __( 'Error: "Table Prefix" is invalid.' ) );
+ wp_die( __( 'Error: "Table Prefix" is invalid.' ) );
}
// Generate keys and salts using secure CSPRNG; fallback to API if enabled; further fallback to original wp_generate_password().
diff --git a/wp-includes/comment.php b/wp-includes/comment.php
index 0d5de2681d..376f0cbca6 100644
--- a/wp-includes/comment.php
+++ b/wp-includes/comment.php
@@ -1270,19 +1270,19 @@ function wp_check_comment_data_max_lengths( $comment_data ) {
$max_lengths = wp_get_comment_fields_max_lengths();
if ( isset( $comment_data['comment_author'] ) && mb_strlen( $comment_data['comment_author'], '8bit' ) > $max_lengths['comment_author'] ) {
- return new WP_Error( 'comment_author_column_length', __( 'Error: Your name is too long.' ), 200 );
+ return new WP_Error( 'comment_author_column_length', __( 'Error: Your name is too long.' ), 200 );
}
if ( isset( $comment_data['comment_author_email'] ) && strlen( $comment_data['comment_author_email'] ) > $max_lengths['comment_author_email'] ) {
- return new WP_Error( 'comment_author_email_column_length', __( 'Error: Your email address is too long.' ), 200 );
+ return new WP_Error( 'comment_author_email_column_length', __( 'Error: Your email address is too long.' ), 200 );
}
if ( isset( $comment_data['comment_author_url'] ) && strlen( $comment_data['comment_author_url'] ) > $max_lengths['comment_author_url'] ) {
- return new WP_Error( 'comment_author_url_column_length', __( 'Error: Your URL is too long.' ), 200 );
+ return new WP_Error( 'comment_author_url_column_length', __( 'Error: Your URL is too long.' ), 200 );
}
if ( isset( $comment_data['comment_content'] ) && mb_strlen( $comment_data['comment_content'], '8bit' ) > $max_lengths['comment_content'] ) {
- return new WP_Error( 'comment_content_column_length', __( 'Error: Your comment is too long.' ), 200 );
+ return new WP_Error( 'comment_content_column_length', __( 'Error: Your comment is too long.' ), 200 );
}
return true;
@@ -3529,9 +3529,9 @@ function wp_handle_comment_submission( $comment_data ) {
if ( get_option( 'require_name_email' ) && ! $user->exists() ) {
if ( '' == $comment_author_email || '' == $comment_author ) {
- return new WP_Error( 'require_name_email', __( 'Error: Please fill the required fields.' ), 200 );
+ return new WP_Error( 'require_name_email', __( 'Error: Please fill the required fields.' ), 200 );
} elseif ( ! is_email( $comment_author_email ) ) {
- return new WP_Error( 'require_valid_email', __( 'Error: Please enter a valid email address.' ), 200 );
+ return new WP_Error( 'require_valid_email', __( 'Error: Please enter a valid email address.' ), 200 );
}
}
@@ -3556,7 +3556,7 @@ function wp_handle_comment_submission( $comment_data ) {
*/
$allow_empty_comment = apply_filters( 'allow_empty_comment', false, $commentdata );
if ( '' === $comment_content && ! $allow_empty_comment ) {
- return new WP_Error( 'require_valid_comment', __( 'Error: Please type your comment text.' ), 200 );
+ return new WP_Error( 'require_valid_comment', __( 'Error: Please type your comment text.' ), 200 );
}
$check_max_lengths = wp_check_comment_data_max_lengths( $commentdata );
@@ -3570,7 +3570,7 @@ function wp_handle_comment_submission( $comment_data ) {
}
if ( ! $comment_id ) {
- return new WP_Error( 'comment_save_error', __( 'Error: The comment could not be saved. Please try again later.' ), 500 );
+ return new WP_Error( 'comment_save_error', __( 'Error: The comment could not be saved. Please try again later.' ), 500 );
}
return get_comment( $comment_id );
diff --git a/wp-includes/load.php b/wp-includes/load.php
index 1b8c325256..8b5d86ba49 100644
--- a/wp-includes/load.php
+++ b/wp-includes/load.php
@@ -624,7 +624,7 @@ function wp_set_wpdb_vars() {
wp_die(
sprintf(
/* translators: 1: $table_prefix, 2: wp-config.php */
- __( 'Error: %1$s in %2$s can only contain numbers, letters, and underscores.' ),
+ __( 'Error: %1$s in %2$s can only contain numbers, letters, and underscores.' ),
'$table_prefix
',
'wp-config.php
'
)
diff --git a/wp-includes/ms-deprecated.php b/wp-includes/ms-deprecated.php
index 9085545bdd..6ce7af2be8 100644
--- a/wp-includes/ms-deprecated.php
+++ b/wp-includes/ms-deprecated.php
@@ -401,7 +401,7 @@ function create_empty_blog( $domain, $path, $weblog_title, $site_id = 1 ) {
// Check if the domain has been used already. We should return an error message.
if ( domain_exists($domain, $path, $site_id) )
- return __( 'Error: Site URL you’ve entered is already taken.' );
+ return __( 'Error: Site URL you’ve entered is already taken.' );
/*
* Need to back up wpdb table names, and create a new wp_blogs entry for new blog.
@@ -410,7 +410,7 @@ function create_empty_blog( $domain, $path, $weblog_title, $site_id = 1 ) {
*/
if ( ! $blog_id = insert_blog($domain, $path, $site_id) )
- return __( 'Error: There was a problem creating site entry.' );
+ return __( 'Error: There was a problem creating site entry.' );
switch_to_blog($blog_id);
install_blog($blog_id);
diff --git a/wp-includes/pluggable.php b/wp-includes/pluggable.php
index c9b7673ce1..a5a0a7b516 100644
--- a/wp-includes/pluggable.php
+++ b/wp-includes/pluggable.php
@@ -622,7 +622,7 @@ if ( ! function_exists( 'wp_authenticate' ) ) :
if ( null == $user ) {
// TODO: What should the error message be? (Or would these even happen?)
// Only needed if all authentication handlers fail to return anything.
- $user = new WP_Error( 'authentication_failed', __( 'Error: Invalid username, email address or incorrect password.' ) );
+ $user = new WP_Error( 'authentication_failed', __( 'Error: Invalid username, email address or incorrect password.' ) );
}
$ignore_codes = array( 'empty_username', 'empty_password' );
diff --git a/wp-includes/user.php b/wp-includes/user.php
index b36619ac9a..1e976f182e 100644
--- a/wp-includes/user.php
+++ b/wp-includes/user.php
@@ -134,11 +134,11 @@ function wp_authenticate_username_password( $user, $username, $password ) {
$error = new WP_Error();
if ( empty( $username ) ) {
- $error->add( 'empty_username', __( 'Error: The username field is empty.' ) );
+ $error->add( 'empty_username', __( 'Error: The username field is empty.' ) );
}
if ( empty( $password ) ) {
- $error->add( 'empty_password', __( 'Error: The password field is empty.' ) );
+ $error->add( 'empty_password', __( 'Error: The password field is empty.' ) );
}
return $error;
@@ -151,7 +151,7 @@ function wp_authenticate_username_password( $user, $username, $password ) {
'invalid_username',
sprintf(
/* translators: %s: User name. */
- __( 'Error: The username %s is not registered on this site. If you are unsure of your username, try your email address instead.' ),
+ __( 'Error: The username %s is not registered on this site. If you are unsure of your username, try your email address instead.' ),
$username
)
);
@@ -176,7 +176,7 @@ function wp_authenticate_username_password( $user, $username, $password ) {
'incorrect_password',
sprintf(
/* translators: %s: User name. */
- __( 'Error: The password you entered for the username %s is incorrect.' ),
+ __( 'Error: The password you entered for the username %s is incorrect.' ),
'' . $username . ''
) .
' ' .
@@ -213,11 +213,11 @@ function wp_authenticate_email_password( $user, $email, $password ) {
if ( empty( $email ) ) {
// Uses 'empty_username' for back-compat with wp_signon().
- $error->add( 'empty_username', __( 'Error: The email field is empty.' ) );
+ $error->add( 'empty_username', __( 'Error: The email field is empty.' ) );
}
if ( empty( $password ) ) {
- $error->add( 'empty_password', __( 'Error: The password field is empty.' ) );
+ $error->add( 'empty_password', __( 'Error: The password field is empty.' ) );
}
return $error;
@@ -248,7 +248,7 @@ function wp_authenticate_email_password( $user, $email, $password ) {
'incorrect_password',
sprintf(
/* translators: %s: Email address. */
- __( 'Error: The password you entered for the email address %s is incorrect.' ),
+ __( 'Error: The password you entered for the email address %s is incorrect.' ),
'' . $email . ''
) .
' ' .
@@ -351,12 +351,12 @@ function wp_authenticate_application_password( $input_user, $username, $password
if ( is_email( $username ) ) {
$error = new WP_Error(
'invalid_email',
- __( 'Error: Unknown email address. Check again or try your username.' )
+ __( 'Error: Unknown email address. Check again or try your username.' )
);
} else {
$error = new WP_Error(
'invalid_username',
- __( 'Error: Unknown username. Check again or try your email address.' )
+ __( 'Error: Unknown username. Check again or try your email address.' )
);
}
} elseif ( ! wp_is_application_passwords_available() ) {
@@ -503,7 +503,7 @@ function wp_authenticate_spam_check( $user ) {
$spammed = apply_filters( 'check_is_user_spammed', is_user_spammy( $user ), $user );
if ( $spammed ) {
- return new WP_Error( 'spammer_account', __( 'Error: Your account has been marked as a spammer.' ) );
+ return new WP_Error( 'spammer_account', __( 'Error: Your account has been marked as a spammer.' ) );
}
}
return $user;
@@ -2830,7 +2830,7 @@ function get_password_reset_key( $user ) {
global $wp_hasher;
if ( ! ( $user instanceof WP_User ) ) {
- return new WP_Error( 'invalidcombo', __( 'Error: There is no account with that username or email address.' ) );
+ return new WP_Error( 'invalidcombo', __( 'Error: There is no account with that username or email address.' ) );
}
/**
@@ -3025,11 +3025,11 @@ function retrieve_password( $user_login = null ) {
}
if ( empty( $user_login ) ) {
- $errors->add( 'empty_username', __( 'Error: Please enter a username or email address.' ) );
+ $errors->add( 'empty_username', __( 'Error: Please enter a username or email address.' ) );
} elseif ( strpos( $user_login, '@' ) ) {
$user_data = get_user_by( 'email', trim( wp_unslash( $user_login ) ) );
if ( empty( $user_data ) ) {
- $errors->add( 'invalid_email', __( 'Error: There is no account with that username or email address.' ) );
+ $errors->add( 'invalid_email', __( 'Error: There is no account with that username or email address.' ) );
}
} else {
$user_data = get_user_by( 'login', trim( wp_unslash( $user_login ) ) );
@@ -3083,7 +3083,7 @@ function retrieve_password( $user_login = null ) {
}
if ( ! $user_data ) {
- $errors->add( 'invalidcombo', __( 'Error: There is no account with that username or email address.' ) );
+ $errors->add( 'invalidcombo', __( 'Error: There is no account with that username or email address.' ) );
return $errors;
}
@@ -3231,7 +3231,7 @@ function retrieve_password( $user_login = null ) {
'retrieve_password_email_failure',
sprintf(
/* translators: %s: Documentation URL. */
- __( 'Error: The email could not be sent. Your site may not be correctly configured to send emails. Get support for resetting your password.' ),
+ __( 'Error: The email could not be sent. Your site may not be correctly configured to send emails. Get support for resetting your password.' ),
esc_url( __( 'https://wordpress.org/support/article/resetting-your-password/' ) )
)
);
@@ -3298,26 +3298,26 @@ function register_new_user( $user_login, $user_email ) {
// Check the username.
if ( '' === $sanitized_user_login ) {
- $errors->add( 'empty_username', __( 'Error: Please enter a username.' ) );
+ $errors->add( 'empty_username', __( 'Error: Please enter a username.' ) );
} elseif ( ! validate_username( $user_login ) ) {
- $errors->add( 'invalid_username', __( 'Error: This username is invalid because it uses illegal characters. Please enter a valid username.' ) );
+ $errors->add( 'invalid_username', __( 'Error: This username is invalid because it uses illegal characters. Please enter a valid username.' ) );
$sanitized_user_login = '';
} elseif ( username_exists( $sanitized_user_login ) ) {
- $errors->add( 'username_exists', __( 'Error: This username is already registered. Please choose another one.' ) );
+ $errors->add( 'username_exists', __( 'Error: This username is already registered. Please choose another one.' ) );
} else {
/** This filter is documented in wp-includes/user.php */
$illegal_user_logins = (array) apply_filters( 'illegal_user_logins', array() );
if ( in_array( strtolower( $sanitized_user_login ), array_map( 'strtolower', $illegal_user_logins ), true ) ) {
- $errors->add( 'invalid_username', __( 'Error: Sorry, that username is not allowed.' ) );
+ $errors->add( 'invalid_username', __( 'Error: Sorry, that username is not allowed.' ) );
}
}
// Check the email address.
if ( '' === $user_email ) {
- $errors->add( 'empty_email', __( 'Error: Please type your email address.' ) );
+ $errors->add( 'empty_email', __( 'Error: Please type your email address.' ) );
} elseif ( ! is_email( $user_email ) ) {
- $errors->add( 'invalid_email', __( 'Error: The email address is not correct.' ) );
+ $errors->add( 'invalid_email', __( 'Error: The email address is not correct.' ) );
$user_email = '';
} elseif ( email_exists( $user_email ) ) {
$errors->add(
@@ -3372,7 +3372,7 @@ function register_new_user( $user_login, $user_email ) {
'registerfail',
sprintf(
/* translators: %s: Admin email address. */
- __( 'Error: Could not register you… please contact the site admin!' ),
+ __( 'Error: Could not register you… please contact the site admin!' ),
get_option( 'admin_email' )
)
);
@@ -3615,7 +3615,7 @@ function send_confirmation_on_profile_email() {
if ( ! is_email( $_POST['email'] ) ) {
$errors->add(
'user_email',
- __( 'Error: The email address is not correct.' ),
+ __( 'Error: The email address is not correct.' ),
array(
'form-field' => 'email',
)
@@ -3627,7 +3627,7 @@ function send_confirmation_on_profile_email() {
if ( email_exists( $_POST['email'] ) ) {
$errors->add(
'user_email',
- __( 'Error: The email address is already used.' ),
+ __( 'Error: The email address is already used.' ),
array(
'form-field' => 'email',
)
diff --git a/wp-includes/version.php b/wp-includes/version.php
index 26f7c7ee55..8b99af0877 100644
--- a/wp-includes/version.php
+++ b/wp-includes/version.php
@@ -16,7 +16,7 @@
*
* @global string $wp_version
*/
-$wp_version = '6.1-alpha-53457';
+$wp_version = '6.1-alpha-53458';
/**
* Holds the WordPress DB revision, increments when changes are made to the WordPress DB schema.
diff --git a/wp-includes/wp-db.php b/wp-includes/wp-db.php
index b514599097..8c6e3df894 100644
--- a/wp-includes/wp-db.php
+++ b/wp-includes/wp-db.php
@@ -3697,7 +3697,7 @@ class wpdb {
// Make sure the server has the required MySQL version.
if ( version_compare( $this->db_version(), $required_mysql_version, '<' ) ) {
/* translators: 1: WordPress version number, 2: Minimum required MySQL version number. */
- return new WP_Error( 'database_version', sprintf( __( 'Error: WordPress %1$s requires MySQL %2$s or higher' ), $wp_version, $required_mysql_version ) );
+ return new WP_Error( 'database_version', sprintf( __( 'Error: WordPress %1$s requires MySQL %2$s or higher' ), $wp_version, $required_mysql_version ) );
}
}
diff --git a/wp-login.php b/wp-login.php
index c805921727..de528842e0 100644
--- a/wp-login.php
+++ b/wp-login.php
@@ -790,9 +790,9 @@ switch ( $action ) {
if ( isset( $_GET['error'] ) ) {
if ( 'invalidkey' === $_GET['error'] ) {
- $errors->add( 'invalidkey', __( 'Error: Your password reset link appears to be invalid. Please request a new link below.' ) );
+ $errors->add( 'invalidkey', __( 'Error: Your password reset link appears to be invalid. Please request a new link below.' ) );
} elseif ( 'expiredkey' === $_GET['error'] ) {
- $errors->add( 'expiredkey', __( 'Error: Your password reset link has expired. Please request a new link below.' ) );
+ $errors->add( 'expiredkey', __( 'Error: Your password reset link has expired. Please request a new link below.' ) );
}
}
@@ -918,7 +918,7 @@ switch ( $action ) {
// Check if password fields do not match.
if ( ! empty( $_POST['pass1'] ) && trim( $_POST['pass2'] ) !== $_POST['pass1'] ) {
- $errors->add( 'password_reset_mismatch', __( 'Error: The passwords do not match.' ) );
+ $errors->add( 'password_reset_mismatch', __( 'Error: The passwords do not match.' ) );
}
/**
@@ -1226,7 +1226,7 @@ switch ( $action ) {
'test_cookie',
sprintf(
/* translators: 1: Browser cookie documentation URL, 2: Support forums URL. */
- __( 'Error: Cookies are blocked due to unexpected output. For help, please see this documentation or try the support forums.' ),
+ __( 'Error: Cookies are blocked due to unexpected output. For help, please see this documentation or try the support forums.' ),
__( 'https://wordpress.org/support/article/cookies/' ),
__( 'https://wordpress.org/support/forums/' )
)
@@ -1237,7 +1237,7 @@ switch ( $action ) {
'test_cookie',
sprintf(
/* translators: %s: Browser cookie documentation URL. */
- __( 'Error: Cookies are blocked or not supported by your browser. You must enable cookies to use WordPress.' ),
+ __( 'Error: Cookies are blocked or not supported by your browser. You must enable cookies to use WordPress.' ),
__( 'https://wordpress.org/support/article/cookies/#enable-cookies-in-your-browser' )
)
);
@@ -1341,7 +1341,7 @@ switch ( $action ) {
if ( isset( $_GET['loggedout'] ) && $_GET['loggedout'] ) {
$errors->add( 'loggedout', __( 'You are now logged out.' ), 'message' );
} elseif ( isset( $_GET['registration'] ) && 'disabled' === $_GET['registration'] ) {
- $errors->add( 'registerdisabled', __( 'Error: User registration is currently not allowed.' ) );
+ $errors->add( 'registerdisabled', __( 'Error: User registration is currently not allowed.' ) );
} elseif ( strpos( $redirect_to, 'about.php?updated' ) ) {
$errors->add( 'updated', __( 'You have successfully updated WordPress! Please log back in to see what’s new.' ), 'message' );
} elseif ( WP_Recovery_Mode_Link_Service::LOGIN_ACTION_ENTERED === $action ) {