How to remove Menu Items that Clients don’t need.

WordPress is great. It has so much functionality that it can get overwhelming especially for clients. Clean up the backend with a couple of simple functions added to the functions.php file in your theme folder. I’ve gone ahead and added a couple, but you can edit the array to your hearts desire.

// Remove unwanted menu Items 
function remove_menus () {
global $menu;
	$restricted = array(
	end ($menu);
	while (prev($menu)){
		$value = explode(' ',$menu[key($menu)][0]);
		if(in_array($value[0] != NULL?$value[0]:"" , $restricted)){unset($menu[key($menu)]);}
add_action('admin_menu', 'remove_menus');