WPIntell

Source evidence

[Plugin: Disable Admin Bar] Plugin doesn't fully disable Admin Bar

Disable Admin Bar · support · 2010-12-03T16:43:00+00:00

complaintsentiment
mediumseverity
0.8relevance
3replies
Evidence linked to opportunitycommercial context

Proof Health

Open evidence

Commercial opportunities need traceable source links before they are treated as build-worthy.

5 / 31 rows with source links

16.1% of this page's analysis has direct source links.

0 build-decision rows missing links

0 rows here require auditable proof before promotion.

26 rows with no attached evidence

0 rows have source counts but still need direct links.

Conversation

support
Brian Zoetewey unresolved
I noticed that just removing the ‘wp_admin_bar_init’ action doesn’t fully disable the admin bar. In admin-header.php, the class ‘admin-bar’ still gets added to the the body tag which results in a 28px padding getting added to the top of the body. A more effective way to remove the admin bar would be: add_filter(‘show_admin_bar’, ‘__return_false’); Hope that helps. http://wordpress.org/extend/plugins/disable-admin-bar/ thanks for posting this! Thank you for this… this works again… the remove wp-admin-bar-init code within the functions.php worked until the latest nightly…. this was a great find thanks for this. Go figure, i searched and searched on how to get this…now I don’t want it lol. I have found this combination works great in version 3.2.1 popped in functions.php. Since tweaking it I now have faster load timesi in both the front and back end of my blogs. // Disable the Admin Bar add_filter( 'show_admin_bar', '__return_false' ); wp_deregister_script('admin-bar'); wp_deregister_style('admin-bar'); remove_action('wp_footer','wp_admin_bar_render',1000); // Remove the Admin Bar preference in user profile */ add_action( 'admin_print_scripts-profile.php', 'hide_admin_bar_prefs' ); function hide_admin_bar_prefs() { ?> <style type="text/css"> .show-admin-bar { display: none; } </style> <?php }

Comments

3 shown
Bill Dennen 2010-12-07T17:24:00+00:00

thanks for posting this!

DJTwittr 2011-01-25T21:23:00+00:00

Thank you for this… this works again… the remove wp-admin-bar-init code within the functions.php worked until the latest nightly…. this was a great find thanks for this. Go figure, i searched and searched on how to get this…now I don’t want it lol.

soblonde 2011-08-29T23:26:00+00:00

I have found this combination works great in version 3.2.1 popped in functions.php. Since tweaking it I now have faster load timesi in both the front and back end of my blogs. // Disable the Admin Bar add_filter( 'show_admin_bar', '__return_false' ); wp_deregister_script('admin-bar'); wp_deregister_style('admin-bar'); remove_action('wp_footer','wp_admin_bar_render',1000); // Remove the Admin Bar preference in user profile */ add_action( 'admin_print_scripts-profile.php', 'hide_admin_bar_prefs' ); function hide_admin_bar_prefs() { ?> <style type="text/css"> .show-admin-bar { display: none; } </style> <?php }