A user asks in WPDevDesign Facebook group:

Considering Oxygen completely disables the theme functions is there a way to get rid of the Admin Menu items ‘Themes’ & ‘Theme Editor’ ?

This tutorial provides the steps to remove Appearance > Themes and Appearance > Theme Editor admin menu items from WordPress admin.

Before:

After:

Step 1

Install and activate Code Snippets plugin.

Step 2

Go to Snippets > Add New.

Title: Remove Appearance > Themes and Appearance > Theme Editor admin menu items

Code:

add_action( 'admin_menu', 'wpdd_remove_menu_items', 999 );
/**
 * Remove Appearance > Themes and Appearance > Theme Editor admin menu items
 */
function wpdd_remove_menu_items() {
	remove_submenu_page( 'themes.php', 'themes.php' );
	remove_submenu_page( 'themes.php', 'theme-editor.php' );
}

Set it to run only in admin.

Save changes and activate.

Source

https://rusticated.co/difficulty/advanced/how-to-remove-items-from-the-wordpress-admin-menu/

Need help implementing a tutorial in your site or want to hire me for custom work?

HIRE ME

Find the article helpful and wish to donate?

DONATE

Comments

You need to be logged in to view and post comments.
Not a member yet? Join here.
magnifiercross
>
linkedin facebook pinterest youtube rss twitter instagram facebook-blank rss-blank linkedin-blank pinterest youtube twitter instagram
%d bloggers like this: