[wp-trac] [WordPress Trac] #28672: add_settings_field & co don't return values

WordPress Trac noreply at wordpress.org
Fri Aug 28 19:59:36 UTC 2015


#28672: add_settings_field & co don't return values
----------------------------------------------+----------------------------
 Reporter:  TJNowell                          |       Owner:  obenland
     Type:  enhancement                       |      Status:  reviewing
 Priority:  normal                            |   Milestone:  4.4
Component:  Options, Meta APIs                |     Version:  2.7
 Severity:  normal                            |  Resolution:
 Keywords:  needs-unit-tests has-patch close  |     Focuses:
                                              |  administration
----------------------------------------------+----------------------------
Changes (by obenland):

 * keywords:  needs-unit-tests has-patch => needs-unit-tests has-patch close


Comment:

 The only time we fail silently is when `do_settings_*()` calls something
 different than what is registered. In all other cases `add_settings_*()`
 will register the page, section, and/or field and everything is peachy.

 With [attachment:28672.3.diff] we'd generate doing it wrong notices on the
 core implementation and every time a field relies on the default section,
 which is not good. We don't have a function to register a settings page,
 so we can't really throw a doing it wrong when a page is not registered.
 Pages are registered with the section or field that are registered to it.

 Which is why I'm saying we should probably not do anything at all here. We
 wouldn't be making things better.

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


More information about the wp-trac mailing list