wpcf7_sanitize_form()CF7 1.0

Sanitizes the form property data.

Хуков нет.

Возвращает

null. Ничего (null).

Использование

wpcf7_sanitize_form( $input, $default_template );
$input (обязательный)
-
$default_template **
-
По умолчанию: ''

Код wpcf7_sanitize_form() CF7 5.9.3

function wpcf7_sanitize_form( $input, $default_template = '' ) {
	if ( null === $input ) {
		return $default_template;
	}

	$output = trim( $input );

	if ( ! current_user_can( 'unfiltered_html' ) ) {
		$output = wpcf7_kses( $output, 'form' );
	}

	return $output;
}