gwaft_modifier_value
Description
Filter an individual value specified for the given modifier.
The primary intent is to provide a mechanism for specifying a custom value that will be replaced with an array of field IDs.
Usage
add_filter( 'gwaft_modifier_value_MODIFIER', 'my_custom_function' );
Parameters
mod_value string
The custom modifier value to be replaced.
$modifier string
The current modifier.
$modifiers array
All modifiers specified for the current merge tag.
$field GF_Field
The current field.
Examples
Exclude Fields with Personal Information
This example shows you how to exclude fields with personal information from instances of the {all_fields}
merge tag that include the custom modifier: {all_fields:exclude[persInfoFields]}
.
<?php
/**
* Gravity Wiz // Gravity Forms // Exclude Fields With Personal Information
*
* This snippet shows you how to exclude fields with personal information from instances
* of the {all_fields} merge tag that include the custom modifier: {all_fields:exclude[persInfoFields]}.
*/
add_filter( 'gwaft_modifier_value_persInfoFields', function() {
return array( 1, 2, 3 );
});