-
Home
-
Perfecty Push Notifications
- Tips
How to Hide Perfecty Push Notifications Admin Menus
function plt_hide_perfecty_push_notifications_menus() {
//Hide "Perfecty Push".
remove_menu_page('perfecty-push');
//Hide "Perfecty Push → Dashboard".
remove_submenu_page('perfecty-push', 'perfecty-push');
//Hide "Perfecty Push → Send notification".
remove_submenu_page('perfecty-push', 'perfecty-push-send-notification');
//Hide "Perfecty Push → Notification jobs".
remove_submenu_page('perfecty-push', 'perfecty-push-notifications');
//Hide "Perfecty Push → Users".
remove_submenu_page('perfecty-push', 'perfecty-push-users');
//Hide "Perfecty Push → Settings".
remove_submenu_page('perfecty-push', 'perfecty-push-options');
//Hide "Perfecty Push → Logs".
remove_submenu_page('perfecty-push', 'perfecty-push-logs');
//Hide "Perfecty Push → About".
remove_submenu_page('perfecty-push', 'perfecty-push-about');
}
add_action('admin_menu', 'plt_hide_perfecty_push_notifications_menus', 11);
Where do I put this code?
How to Hide the "Perfecty Push" Meta Box
function plt_hide_perfecty_push_notifications_metaboxes() {
$screen = get_current_screen();
if ( !$screen ) {
return;
}
//Hide the "Perfecty Push" meta box.
remove_meta_box('perfecty_push_post_metabox', $screen->id, 'side');
}
add_action('add_meta_boxes', 'plt_hide_perfecty_push_notifications_metaboxes', 20);