Created
March 5, 2011 04:24
-
-
Save mitchellhislop/856108 to your computer and use it in GitHub Desktop.
This file contains 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
// Create the function to use in the action hook | |
function example_remove_dashboard_widgets() { | |
// Globalize the metaboxes array, this holds all the widgets for wp-admin | |
global $wp_meta_boxes; | |
// Remove the quickpress widget | |
unset($wp_meta_boxes['dashboard']['side']['core']['dashboard_quick_press']); | |
// Remove the incoming links widget | |
unset($wp_meta_boxes['dashboard']['normal']['core']['dashboard_incoming_links']); | |
} | |
// Hoook into the 'wp_dashboard_setup' action to register our function | |
add_action('wp_dashboard_setup', 'example_remove_dashboard_widgets' ); |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment