Changeset 12778 for trunk/wp-admin/user-new.php
- Timestamp:
- 01/20/2010 09:58:13 PM (16 years ago)
- File:
-
- 1 edited
-
trunk/wp-admin/user-new.php (modified) (5 diffs)
Legend:
- Unmodified
- Added
- Removed
-
trunk/wp-admin/user-new.php
r12764 r12778 63 63 $username = $user_details->user_login; 64 64 $user_id = $user_details->ID; 65 if ( ( $username != null && is_site_admin( $username ) == false) && ( array_key_exists($blog_id, get_blogs_of_user($user_id)) ) ) {65 if ( ( $username != null && !is_super_admin( $user_id ) ) && ( array_key_exists($blog_id, get_blogs_of_user($user_id)) ) ) { 66 66 $redirect = add_query_arg( array('update' => 'addexisting'), 'user-new.php' ); 67 67 } else { 68 if ( isset( $_POST[ 'noconfirmation' ] ) && is_s ite_admin() ) {68 if ( isset( $_POST[ 'noconfirmation' ] ) && is_super_admin() ) { 69 69 add_existing_user_to_blog( array( 'user_id' => $user_id, 'role' => $_REQUEST[ 'role' ] ) ); 70 70 $redirect = add_query_arg( array('update' => 'addnoconfirmation'), 'user-new.php' ); … … 185 185 ?> 186 186 <table class="form-table"> 187 <?php if ( !is_multisite() ) { ?>188 187 <tr class="form-field form-required"> 189 188 <th scope="row"><label for="user_login"><?php _e('Username'); ?> <span class="description"><?php _e('(required)'); ?></span></label> … … 191 190 <td><input name="user_login" type="text" id="user_login" value="<?php echo esc_attr($new_user_login); ?>" aria-required="true" /></td> 192 191 </tr> 193 <tr class="form-field">194 <th scope="row"><label for="first_name"><?php _e('First Name') ?> </label></th>195 <td><input name="first_name" type="text" id="first_name" value="<?php echo esc_attr($new_user_firstname); ?>" /></td>196 </tr>197 <tr class="form-field">198 <th scope="row"><label for="last_name"><?php _e('Last Name') ?> </label></th>199 <td><input name="last_name" type="text" id="last_name" value="<?php echo esc_attr($new_user_lastname); ?>" /></td>200 </tr>201 192 <tr class="form-field form-required"> 202 193 <th scope="row"><label for="email"><?php _e('E-mail'); ?> <span class="description"><?php _e('(required)'); ?></span></label></th> 203 194 <td><input name="email" type="text" id="email" value="<?php echo esc_attr($new_user_email); ?>" /></td> 204 195 </tr> 196 <?php if ( !is_multisite() ) { ?> 197 <tr class="form-field"> 198 <th scope="row"><label for="first_name"><?php _e('First Name') ?> </label></th> 199 <td><input name="first_name" type="text" id="first_name" value="<?php echo esc_attr($new_user_firstname); ?>" /></td> 200 </tr> 201 <tr class="form-field"> 202 <th scope="row"><label for="last_name"><?php _e('Last Name') ?> </label></th> 203 <td><input name="last_name" type="text" id="last_name" value="<?php echo esc_attr($new_user_lastname); ?>" /></td> 204 </tr> 205 205 <tr class="form-field"> 206 206 <th scope="row"><label for="url"><?php _e('Website') ?></label></th> 207 207 <td><input name="url" type="text" id="url" class="code" value="<?php echo esc_attr($new_user_uri); ?>" /></td> 208 208 </tr> 209 210 209 <?php if ( apply_filters('show_password_fields', true) ) : ?> 211 210 <tr class="form-field form-required"> … … 224 223 </tr> 225 224 <?php endif; ?> 226 <?php } else { // multisite ?> 227 <tr class="form-field form-required"> 228 <th scope="row"><label for="user_login"><?php _e('Username (required)') ?></label><input name="action" type="hidden" id="action" value="adduser" /></th> 229 <td ><input name="user_login" type="text" id="user_login" value="<?php echo $new_user_login; ?>" aria-required="true" /></td> 230 </tr> 231 <tr class="form-field form-required"> 232 <th scope="row"><label for="email"><?php _e('E-mail (required)') ?></label></th> 233 <td><input name="email" type="text" id="email" value="<?php echo $new_user_email; ?>" /></td> 234 </tr> 235 <?php } ?> 225 <?php } // !is_multisite ?> 236 226 <tr class="form-field"> 237 227 <th scope="row"><label for="role"><?php _e('Role'); ?></label></th> … … 245 235 </td> 246 236 </tr> 247 248 237 <?php if ( is_multisite() && is_super_admin() ) { ?> 249 <tr class="form-field">238 <tr> 250 239 <th scope="row"><label for="noconfirmation"><?php _e('Skip Confirmation Email') ?></label></th> 251 <td>< input name="noconfirmation" type="checkbox" id="noconfirmation" value="1" /> <label for="noconfirmation"><?php _e( 'Site administrators can add a user without sending the confirmation email.' ); ?></label></td>240 <td><label for="noconfirmation"><input type="checkbox" name="noconfirmation" id="noconfirmation" value="1" /> <?php _e( 'Site administrators can add a user without sending the confirmation email.' ); ?></label></td> 252 241 </tr> 253 242 <?php } ?>
Note: See TracChangeset
for help on using the changeset viewer.