Retrieves an array of registered settings.
Return
array List of registered settings, keyed by option name....$0arrayData used to describe the setting when registered.typestringThe type of data associated with this setting.
Valid values are'string','boolean','integer','number','array', and'object'.labelstringA label of the data attached to this setting.descriptionstringA description of the data attached to this setting.sanitize_callbackcallableA callback function that sanitizes the option’s value.show_in_restbool|arrayWhether data associated with this setting should be included in the REST API.
When registering complex settings, this argument may optionally be an array with a'schema'key.defaultmixedDefault value when callingget_option().
Source
function get_registered_settings() { global $wp_registered_settings; if ( ! is_array( $wp_registered_settings ) ) { return array(); } return $wp_registered_settings; }Related
Used by Description WP_REST_Settings_Controller::get_registered_options() wp-includes/rest-api/endpoints/class-wp-rest-settings-controller.phpRetrieves all of the registered options for the Settings API.
filter_default_option() wp-includes/option.phpFilters the default value for the option.
Changelog
Version Description 4.7.0 Introduced.
User Contributed Notes
You must log in before being able to contribute a note or feedback.