wpcf7_submission_has_disallowed_words

The contact-form-7 wpcf7 submission has disallowed words hook.

Published Date - July 22, 2023

Description

$word = apply_filters(
		'wpcf7_submission_has_disallowed_words',
		$word,
		$submission
	);

Parameters

  1. $word

  2. $submission


Usage

The following example is for adding a hook callback.

// define the wpcf7_submission_has_disallowed_words callback 
function custom_wpcf7_submission_has_disallowed_words( $word, $submission ){ 
   //custom code here
    return $word
} 

//add the action 
add_filter('wpcf7_submission_has_disallowed_words', 'custom_wpcf7_submission_has_disallowed_words', 10, 2)

Defined

The filter is defined in the following location(s).

contact-form-7/modules/disallowed-list.php

$word = apply_filters(
		'wpcf7_submission_has_disallowed_words',
		$word,
		$submission
	);