Changeset 53458 for trunk/src/wp-includes/comment.php
- Timestamp:
- 06/02/2022 03:03:39 PM (3 years ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/src/wp-includes/comment.php
r53299 r53458 1271 1271 1272 1272 if ( isset( $comment_data['comment_author'] ) && mb_strlen( $comment_data['comment_author'], '8bit' ) > $max_lengths['comment_author'] ) { 1273 return new WP_Error( 'comment_author_column_length', __( '<strong>Error </strong>:Your name is too long.' ), 200 );1273 return new WP_Error( 'comment_author_column_length', __( '<strong>Error:</strong> Your name is too long.' ), 200 ); 1274 1274 } 1275 1275 1276 1276 if ( isset( $comment_data['comment_author_email'] ) && strlen( $comment_data['comment_author_email'] ) > $max_lengths['comment_author_email'] ) { 1277 return new WP_Error( 'comment_author_email_column_length', __( '<strong>Error </strong>:Your email address is too long.' ), 200 );1277 return new WP_Error( 'comment_author_email_column_length', __( '<strong>Error:</strong> Your email address is too long.' ), 200 ); 1278 1278 } 1279 1279 1280 1280 if ( isset( $comment_data['comment_author_url'] ) && strlen( $comment_data['comment_author_url'] ) > $max_lengths['comment_author_url'] ) { 1281 return new WP_Error( 'comment_author_url_column_length', __( '<strong>Error </strong>:Your URL is too long.' ), 200 );1281 return new WP_Error( 'comment_author_url_column_length', __( '<strong>Error:</strong> Your URL is too long.' ), 200 ); 1282 1282 } 1283 1283 1284 1284 if ( isset( $comment_data['comment_content'] ) && mb_strlen( $comment_data['comment_content'], '8bit' ) > $max_lengths['comment_content'] ) { 1285 return new WP_Error( 'comment_content_column_length', __( '<strong>Error </strong>:Your comment is too long.' ), 200 );1285 return new WP_Error( 'comment_content_column_length', __( '<strong>Error:</strong> Your comment is too long.' ), 200 ); 1286 1286 } 1287 1287 … … 3530 3530 if ( get_option( 'require_name_email' ) && ! $user->exists() ) { 3531 3531 if ( '' == $comment_author_email || '' == $comment_author ) { 3532 return new WP_Error( 'require_name_email', __( '<strong>Error </strong>:Please fill the required fields.' ), 200 );3532 return new WP_Error( 'require_name_email', __( '<strong>Error:</strong> Please fill the required fields.' ), 200 ); 3533 3533 } elseif ( ! is_email( $comment_author_email ) ) { 3534 return new WP_Error( 'require_valid_email', __( '<strong>Error </strong>:Please enter a valid email address.' ), 200 );3534 return new WP_Error( 'require_valid_email', __( '<strong>Error:</strong> Please enter a valid email address.' ), 200 ); 3535 3535 } 3536 3536 } … … 3557 3557 $allow_empty_comment = apply_filters( 'allow_empty_comment', false, $commentdata ); 3558 3558 if ( '' === $comment_content && ! $allow_empty_comment ) { 3559 return new WP_Error( 'require_valid_comment', __( '<strong>Error </strong>:Please type your comment text.' ), 200 );3559 return new WP_Error( 'require_valid_comment', __( '<strong>Error:</strong> Please type your comment text.' ), 200 ); 3560 3560 } 3561 3561 … … 3571 3571 3572 3572 if ( ! $comment_id ) { 3573 return new WP_Error( 'comment_save_error', __( '<strong>Error </strong>:The comment could not be saved. Please try again later.' ), 500 );3573 return new WP_Error( 'comment_save_error', __( '<strong>Error:</strong> The comment could not be saved. Please try again later.' ), 500 ); 3574 3574 } 3575 3575
Note: See TracChangeset
for help on using the changeset viewer.