Changeset 3369 for trunk/bp-core/bp-core-signup.php
- Timestamp:
- 11/07/2010 12:20:02 AM (15 years ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/bp-core/bp-core-signup.php
r3365 r3369 14 14 if ( $bp->current_component != BP_REGISTER_SLUG ) 15 15 return false; 16 17 $bp->is_directory = false; 16 18 17 19 /* If the user is logged in, redirect away from here */ … … 287 289 288 290 // Add our slugs to the array and allow them to be filtered 289 $filtered_illegal_names = apply_filters( 'bp_core_illegal_usernames', array( 'www', 'web', 'root', 'admin', 'main', 'invite', 'administrator', BP_GROUPS_SLUG, BP_MEMBERS_SLUG, BP_FORUMS_SLUG, BP_BLOGS_SLUG, BP_ACTIVITY_SLUG, BP_XPROFILE_SLUG, BP_FRIENDS_SLUG, BP_SEARCH_SLUG, BP_SETTINGS_SLUG, BP_REGISTER_SLUG, BP_ACTIVATION_SLUG ) ); 291 $filtered_illegal_names = array( 'www', 'web', 'root', 'admin', 'main', 'invite', 'administrator' ); 292 293 if ( bp_is_active( 'activity' ) ) 294 $filtered_illegal_names[] = BP_ACTIVITY_SLUG; 295 296 if ( is_multisite() && bp_is_active( 'blogs' ) ) 297 $filtered_illegal_names[] = BP_BLOGS_SLUG; 298 299 if ( bp_is_active( 'forums' ) ) 300 $filtered_illegal_names[] = BP_FORUMS_SLUG; 301 302 if ( bp_is_active( 'friends' ) ) 303 $filtered_illegal_names[] = BP_FRIENDS_SLUG; 304 305 if ( bp_is_active( 'groups' ) ) 306 $filtered_illegal_names[] = BP_GROUPS_SLUG; 307 308 if ( bp_is_active( 'xprofile' ) ) 309 $filtered_illegal_names[] = BP_XPROFILE_SLUG; 310 311 $filtered_illegal_names[] = BP_ACTIVATION_SLUG; 312 $filtered_illegal_names[] = BP_MEMBERS_SLUG; 313 $filtered_illegal_names[] = BP_REGISTER_SLUG; 314 $filtered_illegal_names[] = BP_SEARCH_SLUG; 315 $filtered_illegal_names[] = BP_SETTINGS_SLUG; 316 $filtered_illegal_names = apply_filters( 'bp_core_illegal_usernames', $filtered_illegal_names ); 290 317 291 318 // Merge the arrays together … … 324 351 bp_core_flush_illegal_names(); 325 352 353 $illegal_names = get_site_option( 'illegal_names' ); 354 326 355 if ( !validate_username( $user_name ) || in_array( $user_name, (array)$illegal_names ) || $user_name != $maybe[0] ) 327 356 $errors->add( 'user_name', __( 'Only lowercase letters and numbers allowed', 'buddypress' ) );
Note: See TracChangeset
for help on using the changeset viewer.