WordPress.org

Make WordPress Core

Changeset 16859


Ignore:
Timestamp:
12/10/10 17:25:04 (3 years ago)
Author:
ryan
Message:

Lose last-blog-admin-visited. Figure out a better way in 3.2

File:
1 edited

Legend:

Unmodified
Added
Removed
  • trunk/wp-admin/admin-header.php

    r16600 r16859  
    3030wp_user_settings(); 
    3131wp_menu_unfold(); 
    32  
    33 // Save the ID of the last blog admin area visited if super admin. 
    34 if ( is_multisite() && is_blog_admin() && is_super_admin() ) { 
    35     $last_blog = get_user_option('last-blog-admin-visited'); 
    36     if ( $last_blog != $blog_id ) 
    37         update_user_option(get_current_user_id(), 'last-blog-admin-visited', $blog_id, true); 
    38     unset($last_blog); 
    39 } 
    4032 
    4133?> 
     
    161153    if ( !is_network_admin() ) 
    162154        $links[10] = '| <a href="' . network_admin_url() . '" title="' . esc_attr__('Network Admin') . '">' . __('Network Admin') . '</a>'; 
    163     elseif ($last_blog = get_user_option('last-blog-admin-visited') ) 
    164         $links[10] = '| <a href="' . get_admin_url($last_blog) . '" title="' . esc_attr__('Site Admin') . '">' . __('Site Admin') . '</a>'; 
     155    else 
     156        $links[10] = '| <a href="' . get_dashboard_url( get_current_user_id() ) . '" title="' . esc_attr__('Site Admin') . '">' . __('Site Admin') . '</a>'; 
    165157} 
    166158$links[15] = '| <a href="' . wp_logout_url() . '" title="' . esc_attr__('Log Out') . '">' . __('Log Out') . '</a>'; 
Note: See TracChangeset for help on using the changeset viewer.