#7682 closed defect (bug) (fixed)
API for adding settings to default settings pages
| Reported by: |
|
Owned by: |
|
|---|---|---|---|
| Priority: | normal | Milestone: | 2.7 |
| Component: | General | Version: | |
| Severity: | normal | Keywords: | |
| Cc: |
Description (last modified by ryan)
Plugins should be able to integrate new settings and new sections of settings into the default settings pages via API.
Attachments (2)
Change History (10)
Patch implements add_settings_section() and add_settings_field() and changes options-writing.php to make use of them.
comment:5
technosailor — 4 years ago
Anybody confirm this is functional for plugins in 2.7? Doesn't seem to work or maybe I'm missing something.
function myex_conf()
{
add_settings_section('myex_settings','My Example Settings','myex_settings','reading');
}
add_action('admin_init','myex_conf');
function myex_settings()
{
echo "foo";
}
comment:6
technosailor — 4 years ago
- Resolution fixed deleted
- Status changed from closed to reopened
The API works fine for writing, discussion, etc - but does not work for reading. Reopening.
- Resolution set to fixed
- Status changed from reopened to closed
Note: See
TracTickets for help on using
tickets.

add_settings_section(), add_settings_field