Skip to content

Commit 294e683

Browse files
authored
Create gpuid-use-uid-field-in-conditional-logic.php
1 parent dbd934c commit 294e683

File tree

1 file changed

+16
-0
lines changed

1 file changed

+16
-0
lines changed
Lines changed: 16 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,16 @@
1+
<?php
2+
/**
3+
* Gravity Perks // Unique ID // Use Unique ID Field in Conditional Logic
4+
* https://gravitywiz.com/documentation/gravity-forms-unique-id/
5+
*/
6+
add_action( 'admin_footer', function() {
7+
if ( wp_script_is( 'gform_form_admin' ) && GFForms::get_page() !== 'form_editor' ) :
8+
?>
9+
<script>
10+
gform.addFilter( 'gform_is_conditional_logic_field', function( isConditionalLogicField, field ) {
11+
return isConditionalLogicField || field.type === 'uid';
12+
} );
13+
</script>
14+
<?php
15+
endif;
16+
} );

0 commit comments

Comments
 (0)