Obviously, most WordPress users do not like to see the WordPress management panel of the website's front-end. of course, there are also many ways to remove the front-end management panel, such as the methods that WPMEE introduced in this article: how to add a user in the management toolbar
Obviously, most WordPress users do not like to see the WordPress management panel of the website's front-end. of course, there are also many ways to remove the front-end management panel, such as the methods that WPMEE introduced in this article: how to add a custom link to the management toolbar involves how to remove the front-end management toolbar. However, they only disable the management bar so that the display: none of the management Bar, JS and CSS are not completely removed. Here we will show you how to completely remove the wordpress front-end management toolbar, including JS and CSS code.
Put the following code in your topic's functions. php to completely remove the wordpress front-end management toolbar:
// Disable Admin Bar, www.wpmee.com
If (! Function_exists ('df _ disable_admin_bar ') {function df_disable_admin_bar () {// for the admin page remove_action ('admin _ footer', 'WP _ admin_bar_render ', 1000 ); // for the front-end remove_action ('WP _ footer ', 'WP _ admin_bar_render', 1000); // css override for the admin page function remove_admin_bar_style_backend () {echo '';} add_filter ('admin _ head', 'remove _ admin_bar_style_backend'); // css override for the frontend function remove_admin_bar_style_frontend () {echo '';} add_filter ('WP _ head', 'remove _ admin_bar_style_frontend ', 99) ;}} add_action ('init', 'df _ disable_admin_bar ');