-
Home
-
Simply Static – The WordPress Static Site Generator
- Tips
How to Hide Simply Static Admin Menus
function plt_hide_simply_static_menus() {
//Hide "Simply Static".
remove_menu_page('simply-static-generate');
//Hide "Simply Static → Generate".
remove_submenu_page('simply-static-generate', 'simply-static-generate');
//Hide "Simply Static → Settings".
remove_submenu_page('simply-static-generate', 'simply-static-settings');
//Hide "Simply Static → Diagnostics".
remove_submenu_page('simply-static-generate', 'simply-static-diagnostics');
}
add_action('admin_menu', 'plt_hide_simply_static_menus', 11);
Where do I put this code?
How to Hide the "Simply Static" Meta Box
function plt_hide_simply_static_metaboxes() {
$screen = get_current_screen();
if ( !$screen ) {
return;
}
//Hide the "Simply Static" meta box.
remove_meta_box('single-export-teaser', $screen->id, 'side');
}
add_action('add_meta_boxes', 'plt_hide_simply_static_metaboxes', 20);