Created
September 18, 2011 21:38
-
-
Save jkudish/1225586 to your computer and use it in GitHub Desktop.
WordPress remove core dashboard widgets
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<?php | |
add_action('wp_dashboard_setup', 'rm_dashboard_widgets'); | |
function rm_dashboard_widgets() { | |
global $wp_meta_boxes; | |
unset($wp_meta_boxes['dashboard']['normal']['core']['dashboard_right_now']); // right now [content, discussion, theme, etc] | |
unset($wp_meta_boxes['dashboard']['normal']['core']['dashboard_plugins']); // plugins | |
unset($wp_meta_boxes['dashboard']['normal']['core']['dashboard_incoming_links']); // incoming links | |
unset($wp_meta_boxes['dashboard']['side']['core']['dashboard_primary']); // wordpress blog | |
unset($wp_meta_boxes['dashboard']['side']['core']['dashboard_secondary']); // other wordpress news | |
unset($wp_meta_boxes['dashboard']['side']['core']['dashboard_quick_press']); // quickpress | |
unset($wp_meta_boxes['dashboard']['side']['core']['dashboard_recent_drafts']); // drafts | |
unset($wp_meta_boxes['dashboard']['normal']['core']['dashboard_recent_comments']); // comments | |
} | |
/* NOTE: you can comment out the dashboard widgets to keep*/ |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment