-
Home
-
User Posts Limit
- Tips
How to Hide the "User Posts Limit" Admin Menu
function plt_hide_user_posts_limit_menus() {
//Hide the "Settings → User Posts Limit" menu.
remove_submenu_page('options-general.php', 'user-posts-limit');
}
add_action('admin_menu', 'plt_hide_user_posts_limit_menus', 11);
Where do I put this code?
How to Hide the "Posts Limit" Dashboard Widget
function plt_hide_user_posts_limit_dashboard_widgets() {
$screen = get_current_screen();
if ( !$screen ) {
return;
}
//Remove the "Posts Limit" widget.
remove_meta_box('upl_limits_widget', 'dashboard', 'normal');
}
add_action('wp_dashboard_setup', 'plt_hide_user_posts_limit_dashboard_widgets', 20);