Description
Filters a widget's settings before saving. Returning false will effectively short-circuit the widget's ability to update settings.
Occurrences
Filename | Line Number |
---|---|
wp-includes/class-wp-widget.php | 476 |
wp-includes/rest-api/endpoints/class-wp-rest-widget-types-controller.php | 502 |
Parameters
Type | Name | Description |
---|---|---|
array | $instance | The current widget instance's settings. |
array | $new_instance | Array of new widget settings. |
array | $old_instance | Array of old widget settings. |
WP_Widget | $widget | The current widget instance. |
PHP Doc
/**
* Filters a widget's settings before saving.
*
* Returning false will effectively short-circuit the widget's ability
* to update settings.
*
* @since 2.8.0
*
* @param array $instance The current widget instance's settings.
* @param array $new_instance Array of new widget settings.
* @param array $old_instance Array of old widget settings.
* @param WP_Widget $widget The current widget instance.
*/