WordPress at Your Fingertips
function is not described

WC_Settings_API::validate_textarea_field() public WC 1.0

Validate Textarea Field.

{} It's a 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.

Code of WC_Settings_API::validate_textarea_field() WC 5.8.0

public function validate_textarea_field( $key, $value ) {
	$value = is_null( $value ) ? '' : $value;
	return wp_kses(
		trim( stripslashes( $value ) ),
		array_merge(
			array(
				'iframe' => array(
					'src'   => true,
					'style' => true,
					'id'    => true,
					'class' => true,
				),
			),
			wp_kses_allowed_html( 'post' )
		)
	);
}