This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<?php | |
/** | |
* Gravity Perks // GP Limit Submissions // Disable Limit Feeds when Editing via Gravity View | |
* http://gravitywiz.com/documentation/gravity-forms-limit-submissions/ | |
*/ | |
add_filter( 'gpls_rule_groups', function( $rule_groups, $form_id ) { | |
if( is_callable( 'gravityview_get_context' ) && gravityview_get_context() == 'edit' ) { | |
$rule_groups = array(); | |
} |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<script> | |
/** | |
* Gravity Perks // GP Copy Cat // Copy Credit Card Name to Name Field | |
* http://gravitywiz.com/ | |
*/ | |
gform.addFilter( 'gppc_copied_value', function( value, $targetElem, field ) { | |
if( field.source.split( '.' ).pop() != 5 ) { | |
return value; | |
} |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<?php | |
/** | |
* Gravity Perks // GP Limit Submissions // Apply Global Limit Collectively | |
* http://gravitywiz.com/documentation/gravity-forms-limit-submissions/ | |
*/ | |
add_filter( 'gpls_apply_limit_per_form', '__return_false' ); |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<?php | |
/** | |
* Gravity Perks // GP Limit Submissions // Apply Limit Feeds Globally | |
* http://gravitywiz.com/documentation/gravity-forms-limit-submissions/ | |
*/ | |
add_filter( 'gpls_rule_groups', function( $rule_groups, $form_id ) { | |
// Update "123" to the ID of your form. | |
$primary_form_id = 123; |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<?php | |
/** | |
* Gravity Perks // GP Limit Submissions // Apply Limit Feeds Globally | |
* http://gravitywiz.com/documentation/gravity-forms-limit-submissions/ | |
*/ | |
add_filter( 'gpls_rule_groups', function( $rule_groups, $form_id ) { | |
// Update "123" to the ID of your form. | |
$primary_form_id = 123; |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<?php | |
/** | |
* Gravity Perks // GP Unique ID // Exclude Unique ID Fields from Gravity PDF | |
* http://gravityperks.com | |
*/ | |
add_filter( 'gform_form_post_get_meta', function( $form ) { | |
foreach( $form['fields'] as &$field ) { | |
if( $field->get_input_type() == 'uid' ) { | |
$field->cssClass = 'exclude'; | |
} |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<?php | |
/** | |
* Gravity Perks // GP Unique ID // HyperDB Support for Sequential IDs | |
* http://gravitywiz.com/documentation/gravity-forms-unique-id/ | |
*/ | |
add_filter( 'gpui_sequential_unique_id_pre_insert', function( $uid, $form_id, $field_id, $starting_number) { | |
global $wpdb; | |
$wpdb->query( 'START TRANSACTION' ); |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<?php | |
/** | |
* Gravity Wiz // Gravity Forms // Better Inventory // Limit by ACF Custom Field | |
* https://gravitywiz.com/better-inventory-with-gravity-forms/ | |
*/ | |
add_filter( 'wp', function() { | |
if( function_exists( 'get_field' ) ) { | |
$gwinv = new GW_Inventory( array( | |
'form_id' => 123, | |
'field_id' => 1.3, |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<?php | |
/** | |
* -------------------------------------------------------------------------- | |
* IMPORTANT! | |
* This snippet has been superceded by the Choice Counter snippet. | |
* https://gist.github.com/spivurno/00af5ee7e21dd5d6903fbae6fecd85ce | |
* -------------------------------------------------------------------------- | |
* | |
* Gravity Wiz // Gravity Forms // Checkbox Count | |
* |