WPCF7_ConfigValidator::detect_html_in_message()publicCF7 1.0

Detects errors of HTML uses in a message.

Метод класса: WPCF7_ConfigValidator{}

Хуков нет.

Возвращает

null. Ничего.

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

$WPCF7_ConfigValidator = new WPCF7_ConfigValidator();
$WPCF7_ConfigValidator->detect_html_in_message( $section, $content );
$section (обязательный)
-
$content (обязательный)
-

Код WPCF7_ConfigValidator::detect_html_in_message() CF7 5.7.7

public function detect_html_in_message( $section, $content ) {
	$stripped = wp_strip_all_tags( $content );

	if ( $stripped != $content ) {
		return $this->add_error( $section,
			self::error_html_in_message,
			array(
				'link' => self::get_doc_link( 'html_in_message' ),
			)
		);
	}

	return false;
}