Created
February 27, 2017 13:51
-
-
Save Alexed93/994386a0cd6283bd573d9c1a022682ed to your computer and use it in GitHub Desktop.
Re-ordering WP Admin menu items
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
// Re-order backend Admin | |
// ------------------------------------------------------------- | |
function custom_menu_order($menu_ord) { | |
if (!$menu_ord) return true; | |
return array( | |
'index.php', // Dashboard | |
'edit.php', // Posts | |
'edit.php?post_type=page', // Pages | |
'edit.php?post_type=team', // Team Members | |
'edit.php?post_type=panel', // Panels | |
'separator1', // First separator | |
'upload.php', // Media | |
'mixd-wp-plugins', // Mixd plugins | |
'themes.php', // Appearance | |
'acf-options', // Options | |
'wpseo_dashboard', // SEO | |
'users.php', // Users | |
'separator2', // Second separator | |
'plugins.php', // Plugins | |
'tools.php', // Tools | |
'bulkpress', // Bulkpress | |
'crazyegg-heatmap-tracking', // Bulkpress | |
'edit.php?post_type=acf-field-group', // Custom fields | |
'options-general.php' // Settings | |
); | |
} | |
add_filter('custom_menu_order', 'custom_menu_order'); // Activate custom_menu_order | |
add_filter('menu_order', 'custom_menu_order'); |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment