[wp-trac] [WordPress Trac] #38129: Rename `dynamic_sidebar` to something more understandable

WordPress Trac noreply at wordpress.org
Thu Sep 22 13:52:12 UTC 2016


#38129: Rename `dynamic_sidebar` to something more understandable
-------------------------+-----------------------------
 Reporter:  ojrask       |      Owner:
     Type:  enhancement  |     Status:  new
 Priority:  normal       |  Milestone:  Awaiting Review
Component:  Widgets      |    Version:  2.2
 Severity:  normal       |   Keywords:
  Focuses:               |
-------------------------+-----------------------------
 Currently, widget areas are registered using `register_sidebar` and
 defining widget areas in templates are done using `dynamic_sidebar`. Other
 related functionalities seem to follow the same naming pattern
 ("sidebar").

 This most probably originates from the 2000s blog-like template structure
 where sidebars were the only logical places to place widgets into.
 Currently, many people are defining widget areas to places which are not
 sidebars (footers, headers, article sections, etc.).

 After working with people who are relatively new to WordPress theme
 development, I've heard multiple complaints about how this is confusing
 and "why can't it be  called something that actually reflects what it
 does".

 Would it be possible to rename all widget-related functions and features
 to something else than a "sidebar"? E.g. `register_widget_area` and
 `dynamic_widget_area`.

 A proper approach might be a tad longer deprecation period (two major
 versions perhaps) because these functions and features are used in so many
 themes.

--
Ticket URL: <https://core.trac.wordpress.org/ticket/38129>
WordPress Trac <https://core.trac.wordpress.org/>
WordPress publishing platform


More information about the wp-trac mailing list