WordPress.org

Make WordPress Core

Changeset 13423


Ignore:
Timestamp:
02/26/10 00:41:23 (5 years ago)
Author:
nacin
Message:

Don't use deprecated functions. Fixes #12377 props filosofo.

Location:
trunk/wp-admin
Files:
4 edited

Legend:

Unmodified
Added
Removed
  • trunk/wp-admin/includes/template.php

    r13389 r13423  
    26292629        return false; 
    26302630 
    2631     $icon = get_attachment_icon( $post->ID ); 
     2631    $icon = wp_get_attachment_image( $post->ID, 'thumbnail', true ); 
    26322632    $attachment_data = wp_get_attachment_metadata( $id ); 
    26332633    $thumb = isset( $attachment_data['thumb'] ); 
  • trunk/wp-admin/ms-edit.php

    r13419 r13423  
    556556 
    557557        $password = wp_generate_password(); 
    558         $user_id = wpmu_create_user(wp_specialchars( strtolower( $user['username'] ) ), $password, esc_html( $user['email'] ) ); 
     558        $user_id = wpmu_create_user(esc_html( strtolower( $user['username'] ) ), $password, esc_html( $user['email'] ) ); 
    559559 
    560560        if ( false == $user_id ) 
  • trunk/wp-admin/ms-sites.php

    r13379 r13423  
    293293                                reset( $editblog_roles ); 
    294294                                foreach ( $editblog_roles as $role => $role_assoc ){ 
    295                                     $name = translate_with_context($role_assoc['name']); 
     295                                    $name = translate_user_role( $role_assoc['name'] ); 
    296296                                    $selected = ( $role == $editblog_default_role ) ? 'selected="selected"' : ''; 
    297297                                    echo "<option {$selected} value=\"" . esc_attr($role) . "\">{$name}</option>"; 
  • trunk/wp-admin/user-new.php

    r13106 r13423  
    8484            } else { 
    8585                $new_user_login = apply_filters('pre_user_login', sanitize_user(stripslashes($_REQUEST['user_login']), true)); 
    86                 if ( isset( $_POST[ 'noconfirmation' ] ) && is_site_admin() ) { 
     86                if ( isset( $_POST[ 'noconfirmation' ] ) && is_super_admin(get_current_user_id()) ) { 
    8787                    add_filter( 'wpmu_signup_user_notification', create_function('', '{return false;}') ); // Disable confirmation email 
    8888                } 
    8989                wpmu_signup_user( $new_user_login, $_REQUEST[ 'email' ], array( 'add_to_blog' => $wpdb->blogid, 'new_role' => $_REQUEST[ 'role' ] ) ); 
    90                 if ( isset( $_POST[ 'noconfirmation' ] ) && is_site_admin() ) { 
     90                if ( isset( $_POST[ 'noconfirmation' ] ) && is_super_admin(get_current_user_id()) ) { 
    9191                    $key = $wpdb->get_var( $wpdb->prepare( "SELECT activation_key FROM {$wpdb->signups} WHERE user_login = %s AND user_email = %s", $new_user_login, $_REQUEST[ 'email' ] ) ); 
    9292                    wpmu_activate_signup( $key ); 
Note: See TracChangeset for help on using the changeset viewer.