From 3c93f01b7283eba194522106aae6cdd93542e917 Mon Sep 17 00:00:00 2001 From: Antoine M Date: Wed, 8 Apr 2026 16:11:57 +0200 Subject: [PATCH] FEATURE Hide default post types from admin menu --- mu-plugins/carhop-post-types.php | 9 +++++++++ 1 file changed, 9 insertions(+) diff --git a/mu-plugins/carhop-post-types.php b/mu-plugins/carhop-post-types.php index e3053e5..c4c80aa 100644 --- a/mu-plugins/carhop-post-types.php +++ b/mu-plugins/carhop-post-types.php @@ -230,3 +230,12 @@ function carhop_create_posttype() ); } add_action('init', 'carhop_create_posttype'); + + +//hide defaukt post type from admin menu +function carhop_hide_default_post_type() +{ + remove_menu_page('edit.php'); + remove_menu_page('edit-comments.php'); +} +add_action('admin_menu', 'carhop_hide_default_post_type');