Revision: 54293
Initial Code
Initial URL
Initial Description
Initial Title
Initial Tags
Initial Language
at December 19, 2011 07:09 by rliverman
Initial Code
if (current_user_can('hide_jobs')) { add_action( 'admin_menu', 'my_remove_menu_jobs' ); function my_remove_menu_jobs() { remove_menu_page('edit.php?post_type=job'); remove_menu_page('edit.php?post_type=solution'); remove_meta_box('dashboard_right_now', 'dashboard', 'normal'); // right now } }
Initial URL
Initial Description
In this example I used the "Members" plugin to add a capability called "hide_jobs" and that was the trigger to hide certain admin menus and also hide the "Right Now" dashboard widget.
Initial Title
Remove or Hide Admin Menu Links for Certain or Specific Users or Roles
Initial Tags
wordpress
Initial Language
PHP