[wp-trac] [WordPress Trac] #15077: is_active_sidebar() cannot accept a sidebar name as input

WordPress Trac wp-trac at lists.automattic.com
Fri Oct 8 20:57:57 UTC 2010


#15077: is_active_sidebar() cannot accept a sidebar name as input
--------------------------+-------------------------------------------------
 Reporter:  dvmorris      |       Owner:                 
     Type:  defect (bug)  |      Status:  new            
 Priority:  normal        |   Milestone:  Awaiting Review
Component:  Widgets       |     Version:  3.0.1          
 Severity:  normal        |    Keywords:  sidebar        
--------------------------+-------------------------------------------------
 If I send a sidebar name, such as "Right Sidebar", to
 is_active_sidebar($index), it does not properly translate the name into
 the sidebar id. The function is on line 971 of wp-includes/widgets.php,
 and the @param comment implies that it is able to accept sidebar names as
 input.

 If you replace line 972 with the logic from dynamic_sidebar() on lines
 842-854, it works properly. Perhaps these lines of code should be moved to
 a function so they do not need to be repeated twice to fix this issue.

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


More information about the wp-trac mailing list