Validates a Customize setting value.
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.
$validityWP_Error
true to WP_Error when invalid.$valuemixed
$settingWP_Customize_Setting
$validity = apply_filters( "customize_validate_{$this->id}", $validity, $value, $this );
| Version | Description |
|---|---|
| 4.6.0 | Introduced. |
© 2003–2024 WordPress Foundation
Licensed under the GNU GPLv2+ License.
https://developer.wordpress.org/reference/functions/customize_validate_this-id