Take the 2-minute tour ×
WordPress Development Stack Exchange is a question and answer site for WordPress developers and administrators. It's 100% free, no registration required.

Is there a way to have "Pages" set as the default tab when the user logs in to the admin area? I am using a heavily customised set up, where none of the dashboard widgets are useful so they are hidden anyway.

share|improve this question

2 Answers 2

up vote 1 down vote accepted

The best way is to re-direct user logins to your page and also remove the dashboard from the menu, this can be done with 2 filters.

Redirect logins to your page edit screen example based on user roles, this example uses "author":

function dashboard_redirect($url) {
    global $current_user;
    // is there a user ?
    if(is_array($user->roles)) {
        // check, whether user has the author role:
        if(in_array('author', $current_user->roles)) {
             $url = 'edit.php?post_type=page';
        }
        return $url;
    }
}
add_filter('login_redirect', 'dashboard_redirect');   

Remove the "dashboard from the admin menu"

add_action( 'admin_menu', 'Wps_remove_tools', 99 );
function Wps_remove_tools(){

    remove_menu_page( 'index.php' ); //dashboard

   }

ps. You can also order the admin menu items using the same filter.

share|improve this answer

Yes, use Adminimize Plugin, remove dashboard and let the pages be the first screen when an use logs in. You can customize it very well and do a fine tuning of the entire admin backend!

UPDATE

Use the filter 'login_redirect' and use the admin_url like in this Wordpress Stackechange post:

Change default admin page for specific role(s)

share|improve this answer
    
I am wary of using such a comprehensive plugin for a single purpose. Ideally I'd build this into my custom themes functions.php –  Tom Jan 16 '12 at 13:45

Your Answer

 
discard

By posting your answer, you agree to the privacy policy and terms of service.

Not the answer you're looking for? Browse other questions tagged or ask your own question.