This topic has 5 replies, 2 voices, and was last updated 9 years by Radu.

  • Author
  • #113284
     jasonmwestbrook
    Participant

    I am having trouble hiding the admin top bar from showing up for non admin users. I have disabled all plugins and still shows it. I have it set to enabled. If I disable it then I am unable to go to backend.

    Please advise

    #113328
     Radu
    Moderator

    Hi,

    You can access dashboard by accessing http://www.connectable.church/wp-admin

    Cheers

    Radu

    Hi there!!! Help others from the community and mark any reply as solution if it solved your question. Mark as a solution
    #113388
     jasonmwestbrook
    Participant

    I mean….I need it hidden but only to show up for admins. It’s showing up for everyone.

    #113531
     Radu
    Moderator

    Hi,

    Add this snippet to your child theme ( wp-content/themes/kleo-child/functions.php )

    COPY CODE
    add_action('after_setup_theme', 'remove_admin_bar');
    
    function remove_admin_bar() {
    if (!current_user_can('administrator') && !is_admin()) {
      show_admin_bar(false);
    }
    }
    

    Let me know

    Cheers

    Radu

    Hi there!!! Help others from the community and mark any reply as solution if it solved your question. Mark as a solution
    #113658
     jasonmwestbrook
    Participant

    Code added. Still nothing. Please advise.

    #113817
     Radu
    Moderator

    Hi,

    Please try this plugin : https://wordpress.org/plugins/hide-admin-bar-from-non-admins/

    Cheers

    Hi there!!! Help others from the community and mark any reply as solution if it solved your question. Mark as a solution
Viewing 6 posts - 1 through 6 (of 6 total)

The forum ‘Bugs & Issues’ is closed to new topics and replies.

Log in with your credentials

Forgot your details?