• Resolved jkdev

    (@jkdev)


    Hello! Great plugin!

    I just have a question regarding a multisite network. Is there a way to hide the WP Security menu on the left for admins? I only want it to show for the Super Admin.

    Thank you!

    Edit:

    Is there a way to do it built in? I just discovered this method and will post it here to help anybody else.

    if ( !is_super_admin() ) {
    add_action( ‘admin_menu’, ‘remove_wp_menu’ );
    }
    function remove_wp_menu() {
    remove_menu_page( ‘aiowpsec’ );
    }

    Is that safe and the right way to do it? It seems to work fine and I get no errors.

    • This topic was modified 6 years, 5 months ago by jkdev.
    • This topic was modified 6 years, 5 months ago by jkdev.
    • This topic was modified 6 years, 5 months ago by jkdev.
Viewing 2 replies - 1 through 2 (of 2 total)
  • Plugin Contributor mbrsolution

    (@mbrsolution)

    Hi, that function looks correct to me. Was the code added to your themes functions.php file?

    If it is not giving you any problems then I would say it is safe to keep using it. However make sure you keep track of this change, just in case something else happens late on.

    Kind regards

    • This reply was modified 6 years, 5 months ago by mbrsolution.
    Thread Starter jkdev

    (@jkdev)

    Hi @mbrsolution,

    Thank you for the reply! Yes I added it to my child theme functions.php.

    No problems I can tell, thanks for the advice!

    Awesome plugin by the way. So much better than WF!

Viewing 2 replies - 1 through 2 (of 2 total)
  • The topic ‘Admin Menu Only for Super Admin?’ is closed to new replies.