Wordpress top bar appearing on frontend

Wp…in the fontend has a top bar with options such as customize…new…plugins update info…

I assume you understand what I am talking about…

The problem with it…is that it appears on the frontend…I obviously do not want my users see this when they visit my sites’s blog…

How to remove it?

never-mind I found the solution

Hi there,

The WordPress admin bar will display whenever you are logged into the site. You can disable it from showing on the front-end by adding the following script into your functions.php inside your active WordPress template:

add_filter('show_admin_bar', '__return_false');

You can disable the admin bar for a specific set of registered users based on user level (admin, editor, etc)

if (!current_user_can(‘manage_options’)) {  add_filter(‘show_admin_bar’, ‘__return_false’);  }

Hope that helps.

1 Like

This topic was automatically closed 91 days after the last reply. New replies are no longer allowed.