gform_advancedpostcreation_editable_fields_excluded_types

Description

The gform_advancedpostcreation_editable_fields_excluded_types filter allows add-ons and developers to modify the list of field types excluded from the editable fields list in the Gravity Forms Advanced Post Creation Add-On.

Usage

add_filter( 'gform_advancedpostcreation_editable_fields_excluded_types', 'your_function_name' );

Parameters

NameTypeDescription
$excluded_typesarrayArray of field types to exclude from the editable fields list.

Default values

[
	'captcha',
	'creditcard',
	'hidden',
	'hiddenproduct',
	'html',
	'page',
	'password',
	'product',
	'quantity',
	'option',
	'section',
	'shipping',
	'submit',
	'total',
	'turnstile',
	'username',
]

Examples

Add a custom field type.

This example shows how to exclude a custom field type named my_field_type from the editable fields list.

add_filter( 'gform_advancedpostcreation_editable_fields_excluded_types', 'add_my_field_type' );
function add_my_field_type( $fields ) {
    $fields[] = 'my_field_type';
    return $fields;
}

Add the checkbox field type to the excluded list.

add_filter( 'gform_advancedpostcreation_editable_fields_excluded_types', function( $excluded_types ) {
    $excluded_types[] = 'checkbox';
    return $excluded_types;
});

Placement

This code can be used in the functions.php file of the active theme, a custom functions plugin, a custom add-on, or with a code snippets plugin.

See also the PHP section in this article: Where Do I Put This Code?

Source Code

This filter is located in class-gf-advancedpostcreation.php.

Since

Added in Gravity Forms Advanced Post Creation Add-On v1.6.0.