On this page
apply_filters( "customize_validate_{$this->id}", WP_Error $validity, mixed $value, WP_Customize_Setting $setting )
Validates a Customize setting value.
Description
Plugins should amend the $validity object via its WP_Error::add() method.
The dynamic portion of the hook name, $this->ID, refers to the setting ID.
Parameters
$validityWP_Error-
Filtered from
truetoWP_Errorwhen invalid. $valuemixed-
Value of the setting.
$settingWP_Customize_Setting-
WP_Customize_Setting instance.
Source
File: wp-includes/class-wp-customize-setting.php. View all references
$validity = apply_filters( "customize_validate_{$this->id}", $validity, $value, $this );
Related
Used By
| Used By | Description |
|---|---|
| WP_Customize_Setting::validate() wp-includes/class-wp-customize-setting.php | Validates an input. |
Changelog
| Version | Description |
|---|---|
| 4.6.0 | Introduced. |
© 2003–2022 WordPress Foundation
Licensed under the GNU GPLv2+ License.
https://developer.wordpress.org/reference/hooks/customize_validate_this-id