-
Home
-
Follow Hook
- Tips
How to Hide Follow Hook Admin Menus
function plt_hide_follow_hook_menus() {
//Hide "Follow Hook".
remove_menu_page('follow_hook_settings');
//Hide "Follow Hook → Dashboard".
remove_submenu_page('follow_hook_settings', 'follow_hook_settings');
//Hide "Follow Hook → People".
remove_submenu_page('follow_hook_settings', 'edit.php?post_type=people');
//Hide "Follow Hook → Groups".
remove_submenu_page('follow_hook_settings', 'edit-tags.php?taxonomy=pods&post_type=people');
//Hide "Follow Hook → Tags".
remove_submenu_page('follow_hook_settings', 'edit-tags.php?taxonomy=people_tags&post_type=people');
//Hide "Follow Hook → Touchpoints".
remove_submenu_page('follow_hook_settings', 'edit.php?post_type=touchpoints');
//Hide "Follow Hook → Today's Touchpoints".
remove_submenu_page('follow_hook_settings', 'Follow_Hook_daily_touchpoints');
//Hide "Follow Hook → Forms".
remove_submenu_page('follow_hook_settings', 'Follow_Hook_forms_admin_pg');
//Hide "Follow Hook → Custom Fields".
remove_submenu_page('follow_hook_settings', 'Follow_Hook_custom_fields_admin_pg');
}
add_action('admin_menu', 'plt_hide_follow_hook_menus', 1000);
Where do I put this code?
How to Hide Follow Hook Meta Boxes
function plt_hide_follow_hook_metaboxes() {
$screen = get_current_screen();
if ( !$screen ) {
return;
}
//Hide the "Touchpoint Information" meta box.
remove_meta_box('create_touchpoint_tabs', $screen->id, 'normal');
//Hide the "Person's General Information" meta box.
remove_meta_box('people_metabox_basic_info', $screen->id, 'normal');
}
add_action('add_meta_boxes', 'plt_hide_follow_hook_metaboxes', 20);