I can't deselect "enable administration menus - plugins"


I'm trying to deselect the "plugins" checkbox under "Network Settings < Network Admin - WordPress" so new multisite admins don't have access to plugins, but everytime I save the update the checkbox is still selected. :slight_frown:

Any other way I can force this to deselect, or could this be dependant on another setting or plugin (e.g Pro Sites?) that may prevent me from deselecting it?


  • aristath
    • Recruit

    Are you using the Premium Plugins addon for the Pro-Sites plugin?
    If you are then yes, the plugins will be forced to be displayed.
    You will have to custom-code something to hide the plugins menu...

    Try this:

    function aristath_custom_remove_menus () {
    	if( !current_user_can( 'manage_network' ) ) {
    		global $menu;
    		$restricted = array( __('Links'), __('Tools'), __('Settings'), __('Plugins') );
    		end ($menu);
    		while ( prev( $menu ) ) {
    			$value = explode( ' ',$menu[key($menu)][0] );
    			if( in_array( $value[0] != NULL?$value[0]:"" , $restricted ) ) :
    				unset( $menu[key( $menu )] );
    		remove_menu_page( 'plugins.php' );
    add_action('admin_menu', 'aristath_custom_remove_menus', 10);


Thank NAME, for their help.

Let NAME know exactly why they deserved these points.

Gift a custom amount of points.