[wp-trac] [WordPress Trac] #53489: Widgets: Registered sidebar not showing in the widget editor

WordPress Trac noreply at wordpress.org
Wed Jun 23 21:47:26 UTC 2021


#53489: Widgets: Registered sidebar not showing in the widget editor
---------------------------+---------------------
 Reporter:  walbo          |       Owner:  (none)
     Type:  defect (bug)   |      Status:  new
 Priority:  normal         |   Milestone:  5.8
Component:  Widgets        |     Version:
 Severity:  normal         |  Resolution:
 Keywords:  needs-testing  |     Focuses:
---------------------------+---------------------

Comment (by hellofromTonya):

 == Further testing

 Same results on 5.8 Beta 2.

 What happens when registering multiple sidebars:


 {{{#!php
 <?php
         register_sidebar(
                 array(
                         'name'          => esc_html__( 'My Sidebar',
 'twentytwentyone' ),
                         'id'            => 'my-sidebar',
                 )
         );

         register_sidebar(
                 array(
                         'name'          => esc_html__( 'Sidebar #2',
 'twentytwentyone' ),
                         'id'            => 'sidebar-2',
                 )
         );

         register_sidebar(
                 array(
                         'name'          => esc_html__( 'Sidebar1',
 'twentytwentyone' ),
                         'id'            => 'sidebar1',
                 )
         );
 }}}


 - Go to `Appearance` > `Widgets` => Results: `'sidebar-2'` renders but
 `'my-sidebar'` and `'sidebar1'` do not.
 - Go to another screen like `Themes`, then return to `Widgets` => Results:
 same
 - Go to `Plugins` > `Add New` > `Classic Widgets` and activate it
 - Go to `Appearance` > `Widgets` => Results: all sidebars appear
 - Go back to `Plugins` and deactivate the `Classic Widgets` plugin
 - Go back to `Widgets` => Results: All sidebars appear
 - Delete the new sidebars and refresh the screen => Results: the sidebars
 are gone
 - Add code back in and then refresh => Results: all sidebars appear again
 - Rename the ID of `Sidebar #2` to `sidebar-3` and refresh the screen =>
 Results: that sidebar no longer renders
 - Repeat activating the `Classic Widgets` plugin, going to the `Widgets`
 screen, and then deactivating the plugin, and then going back to the
 `Widgets` screen => Results: sidebar renders as expected

-- 
Ticket URL: <https://core.trac.wordpress.org/ticket/53489#comment:6>
WordPress Trac <https://core.trac.wordpress.org/>
WordPress publishing platform


More information about the wp-trac mailing list