|
/ Documentation /Developer Documentation/Filter Hooks/ srfm_additional_restriction_check

srfm_additional_restriction_check

Description

Filters an additional, custom restriction check during submission. Return true to block the submission with your own rule. Defaults to false.

Parameters

  • $is_restricted (bool) – Defaults to false.
  • $form_id (int) – The form ID.
  • $form_data (array) – The submitted form data.

Filter Source

PHP
/**
* filter source (Free) inc/form-submit.php 
*/
$is_restricted = apply_filters( 'srfm_additional_restriction_check', false, $form_id, $form_data );

Filter Usage

PHP
add_filter( 'srfm_additional_restriction_check', 'my_callback', 10, 3 ); 
function my_callback( $is_restricted, $form_id, $form_data ) { 
return $is_restricted; 
// return true to block. 
}

Filter Example

PHP
add_filter( 'srfm_additional_restriction_check', 'my_callback', 10, 3 ); 
function my_callback( $is_restricted, $form_id, $form_data ) { 
return $is_restricted; 
}
Was this doc helpful?
What went wrong?

We don't respond to the article feedback, we use it to improve our support content.

Need help? Contact Support
Table of Contents
Scroll to Top