[wp-trac] [WordPress Trac] #19766: Admin bar should be able to be turned off in admin area

WordPress Trac wp-trac at lists.automattic.com
Fri Jan 6 18:23:51 UTC 2012


#19766: Admin bar should be able to be turned off in admin area
--------------------------+-----------------------------
 Reporter:  ericlewis     |      Owner:
     Type:  defect (bug)  |     Status:  new
 Priority:  normal        |  Milestone:  Awaiting Review
Component:  UI            |    Version:  3.3.1
 Severity:  normal        |   Keywords:
--------------------------+-----------------------------
 In reference to [http://core.trac.wordpress.org/ticket/18197], Nacin added
 a patch that enforces the admin bar on when in the admin area. This
 invalidates part of the utility of show_admin_bar(), which can be used to
 change whether the admin bar will be shown via modifying the global
 $show_admin_bar. Plugin authors may find themselves in a situation that
 they wanted to do away with the admin bar, even in the admin area, as
 BuddyPress did until this changeset.

 This logic is held within is_admin_bar_showing() (admin-bar.php:710).
 Currently if is_admin() returns true is_admin_bar_showing returns true.
 I'm suggesting adding an AND condition to validate against the global
 $show_admin_bar as well, which is what this global is intended to be used
 for.

 Although I found this bug while working with BuddyPress, I feel that the
 utility may be applicable in other situations, and keeping WP more
 flexible than less flexible is a good idea.

-- 
Ticket URL: <http://core.trac.wordpress.org/ticket/19766>
WordPress Trac <http://core.trac.wordpress.org/>
WordPress blogging software


More information about the wp-trac mailing list