Say Bye-Bye to the WP 3.1 Admin Bar
While WP 3.1 is still a work in progress, many of us are starting to migrate test sites up to WordPress 3.1 to be sure our blogs function well on it.
WordPress 3.1 comes by default with a new function called an Admin Bar that is added to both the front and back-end of your site when your logged in.
Former WordPress.com users may feel right at home… but many WordPress.org users are not amused with this new feature and would prefer to disable the WP 3.1 Admin Bar.
It looks like this….
I know that picture’s not real great, but its the gray bar running at the top of my view of my site with a search box/etc.
Click on the picture if you want to see a larger view.
This can be very handy in multi-user blogs but for those of us that have single-user blogs its pretty much just annoying.
Since release candidate 2 you can disable it on a per user basis…
That’s helpful, but many people just want it to go away.
How To Fully Disable The WordPress 3.1 Admin Bar
Two solutions exist to make it go away:
For those less tech savvy….
Ozh has already created a plugin that will disable the admin bar.
The Disable Admin Bar plugin essentially creates the same behavior as the code below (except that its a plugin, so has some weight of its own but does not force you to edit any scary code)
For those slightly more tech savvy….
Yoast recently shared the code we need to disable the WordPress 3.1 Admin bar for all users.
The code below can be added to your themes functions.php file (or custom_functions.php for thesis)
The functions.php file is located inside the theme directory. You need to create one, if it does not exists yet.
To disable the admin bar, add the following code into your functions.php file.
<?php /* Disable the Admin Bar. */ remove_action( 'init', 'wp_admin_bar_init' ); ?>
Some thoughts on Removing the WordPress 3.1 Admin Bar
I’m not real sure who’s idea it was that WordPress.org blogs needed to look more like the WordPress.com site but it is what it is and we’ll live with it.
This bar certainly can have its uses in certain multi-user blog situations but for many of us, whether we’re just picky or because it clashes with the visual enjoyment of our layout, its not a appreciated addition.
As long as the “disable by user” option that was recently added to the release candidate #2 makes it into the final version of WordPress 3.1 I do not think most of us with single-user blogs will need either of these solutions as we can easily disable it for ourselves on our single user blogs.
However, for multi-user blogs such as speed2trust.info and other sites that have many members and already have their own integrated toolbars (and the members have no business being in the backend of the blog), this bit of code is very useful for disabling the WordPress 3.1 Admin Bar for all users at one time.
Here’s To Your Success,
PS: Usually we do not go much beyond RC2 (release candidate 2) before a final version is considered adequately tested and stable. I would expect to see WordPress 3.1 go live in the next one to two weeks. (Probably on the shorter side of that.)