Changeset 35142 for trunk/src/wp-includes/ms-functions.php
- Timestamp:
- 10/13/2015 05:32:17 PM (9 years ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/src/wp-includes/ms-functions.php
r35024 r35142 414 414 415 415 if ( $user_name != $orig_username || preg_match( '/[^a-z0-9]/', $user_name ) ) { 416 $errors->add( 'user_name', __( ' Only lowercase letters (a-z) and numbers are allowed.' ) );416 $errors->add( 'user_name', __( 'Usernames can only contain lowercase letters (a-z) and numbers.' ) ); 417 417 $user_name = $orig_username; 418 418 } … … 440 440 $errors->add( 'user_name', __( 'Username may not be longer than 60 characters.' ) ); 441 441 } 442 443 if ( strpos( $user_name, '_' ) !== false )444 $errors->add( 'user_name', __( 'Sorry, usernames may not contain the character “_”!' ) );445 442 446 443 // all numeric? … … 562 559 $errors->add('blogname', __( 'Please enter a site name.' ) ); 563 560 564 if ( preg_match( '/[^a-z0-9]+/', $blogname ) ) 565 $errors->add('blogname', __( 'Only lowercase letters (a-z) and numbers are allowed.' ) ); 561 if ( preg_match( '/[^a-z0-9]+/', $blogname ) ) { 562 $errors->add( 'blogname', __( 'Site names can only contain lowercase letters (a-z) and numbers.' ) ); 563 } 566 564 567 565 if ( in_array( $blogname, $illegal_names ) ) … … 570 568 if ( strlen( $blogname ) < 4 && !is_super_admin() ) 571 569 $errors->add('blogname', __( 'Site name must be at least 4 characters.' ) ); 572 573 if ( strpos( $blogname, '_' ) !== false )574 $errors->add( 'blogname', __( 'Sorry, site names may not contain the character “_”!' ) );575 570 576 571 // do not allow users to create a blog that conflicts with a page on the main blog.
Note: See TracChangeset
for help on using the changeset viewer.