gpnf_item_labels
Description
Filter the label used to identify entries in a Nested Form field.
Usage
Apply to all forms and fields.
add_filter( 'gpnf_item_labels', 'my_custom_function' );
Apply to all fields for a specific form.
add_filter( 'gpnf_item_labels_FORMID', 'my_custom_function' );
Apply to a specific form and field.
add_filter( 'gpnf_item_labels_FORMID_FIELDID', 'my_custom_function' );
Parameters
item_labels array
Example
Set custom labels.
Set custom labels for both singular and plural values. This overrides any setting made in the Nested Form field settings.
add_filter( 'gpnf_item_labels', function() {
return array(
'singular' => __( 'employee', 'gravityperks' ),
'plural' => __( 'employees', 'gravityperks' )
);
} );
Since
This filter is available since Gravity Forms Nested Forms 1.0.