Support » Fixing WordPress » Please help me to remove the top tool bar for suscribers

Viewing 11 replies - 1 through 11 (of 11 total)
  • Moderator keesiemeijer

    (@keesiemeijer)

    moderator

    Put this in your theme’s functions.php: show_admin_bar(false);

    watchersnplayers

    (@watchersnplayers)

    Well I want to remove the tool bar only for Subscribers not for Admin.
    is there anyway please help me

    Moderator keesiemeijer

    (@keesiemeijer)

    moderator

    if (!current_user_can('administrator')) { show_admin_bar(false); }

    or

    if (!current_user_can('manage_options') ) { show_admin_bar(false); }

    watchersnplayers

    (@watchersnplayers)

    is it like this

    show_admin_bar(false);
    if (!current_user_can(‘administrator’)) { show_admin_bar(false); }

    /

    show_admin_bar(false);
    if (!current_user_can(‘manage_options’) ) { show_admin_bar(false); }

    Moderator keesiemeijer

    (@keesiemeijer)

    moderator

    Try one of the two.

    watchersnplayers

    (@watchersnplayers)

    Can you please Check my Code because its not working
    The tool bar is not showing for me (Administrator )

    Moderator keesiemeijer

    (@keesiemeijer)

    moderator

    Try this one in functions.php :
    if (!current_user_can('manage_options') ) { show_admin_bar(false); }

    watchersnplayers

    (@watchersnplayers)

    I had used like this and it not working.

    “show_admin_bar(false);
    if (!current_user_can(‘manage_options’) ) { show_admin_bar(false); } “

    and its still hiding the tool bar for me 🙁

    Moderator keesiemeijer

    (@keesiemeijer)

    moderator

    not:

    show_admin_bar(false);
    if (!current_user_can('manage_options') ) { show_admin_bar(false); }

    but only:

    if (!current_user_can('manage_options') ) { show_admin_bar(false); }

    watchersnplayers

    (@watchersnplayers)

    that Worked Great 🙂

    thanks

    GREAT job 🙂

    Moderator keesiemeijer

    (@keesiemeijer)

    moderator

    You’re welcome. I’m glad you got it resolved.

Viewing 11 replies - 1 through 11 (of 11 total)
  • The topic ‘Please help me to remove the top tool bar for suscribers’ is closed to new replies.