0

How do you force the wordpress dashboard to be 1 coulmn by default? I want to show the dashboard as a single column for all users.

4

I found a promising looking answer to this question in the following post: http://wordpress.org/support/topic/customizing-admin-area-using-functionsphp-2-questions

It recommends using this code in the functions.php file:

function so_screen_layout_columns( $columns ) {
    $columns['dashboard'] = 1;
    return $columns;
}
add_filter( 'screen_layout_columns', 'so_screen_layout_columns' );

function so_screen_layout_dashboard() {
    return 1;
}
add_filter( 'get_user_option_screen_layout_dashboard', 'so_screen_layout_dashboard' );

Hope that helps!

2
  • Is there a way to force 3 column dashboard for a certain browser width?
    – Amjad
    Apr 19 '17 at 21:07
  • Wow, great question @Amjad! I've moved away from WP over the years, but I would think that you'd need to capture the width using .js upon window resize and re-query the WP back end when the browser reached the desired width. Sorry I don't have a better answer, perhaps someone else will comment more specifically.
    – dbonomo
    Apr 21 '17 at 15:59

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

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