You can remove the admin bar via your profile settings in the backend or you can add the following code to your functions.php.
/*
* Remove the admin bar and admin bar settings
*/
add_action( 'init', 'disable_admin_bar' , 9 );
function disable_admin_bar() {
// Hide Admin Bar
add_filter( 'show_admin_bar', '__return_false' );
add_action( 'admin_print_scripts-profile.php',
'hide_admin_bar_settings' );
}
Thread Starter
Andrew
(@ndrwglrzayahoocom)
Okay, never mind. I seem to have figured it out. I had it set to show on the dashboard.. But it wasn’t showing anyway? Just the space for it was apparent.
Anyway, I got it hidden now.
Thank you,
Andrew
Thread Starter
Andrew
(@ndrwglrzayahoocom)
Okay, thank you, w1nk5.
Does this remove the code or hide it? Some people said that the code still takes up memory if you just hide it.
Please help.
Thank you,
Andrew
The code above will stop the admin bar from loading when WordPress is initializing.