WC_Settings_API::validate_textarea_field()
Validate Textarea Field.
Method of the class: WC_Settings_API{}
No Hooks.
Return
String
.
Usage
$WC_Settings_API = new WC_Settings_API(); $WC_Settings_API->validate_textarea_field( $key, $value );
- $key(string) (required)
- Field key.
- $value(string) (required)
- Posted Value.
Changelog
Since 9.0.0 | Introduced. |
Since 9.0.0 | No longer allows storing IFRAME, which was allowed for "ShareThis" integration no longer found in core. |
WC_Settings_API::validate_textarea_field() WC Settings API::validate textarea field code WC 9.6.1
public function validate_textarea_field( $key, $value ) { $value = is_null( $value ) ? '' : $value; return wp_kses_post( trim( stripslashes( $value ) ) ); }