Logic on a Gravity Forms redirect [closed]

If anyone runs into this problem, the answer lies in the fact that gform_confirmation is fired after gform_after_submission. The logic is correct, however, the 5th session variable was not being stored before the confirmation was sent. Therefore, no variable ever equaled ‘No’ and it failed every time. The solution is to call the $entry in … Read more

Require user to input code from an array of allowed codes with Gravity Forms [closed]

Try below code: add_filter( ‘gform_field_validation’, ‘custom_validation’, 10, 4 ); function custom_validation( $result, $value, $form, $field ) { $arrWhitelist = array(‘XH6D’, ‘8U2A’, ‘L9D3’); if ( $result[‘is_valid’] && !in_array( $value, $arrWhitelist )) { $result[‘is_valid’] = false; $result[‘message’] = ‘Please enter a value less than 10’; } return $result; } Further, You can review validation in more detail … Read more

Convert Gravity Form Entry Date on Export

You can’t modify date_created on Export Gravity Forms date_created field isn’t actually a field that’s affected by that hook. If you look in /exports.php you’ll find in start_export() that they bypass the filter for ID’s date_created and payment_date and hard-code force the use of Y-m-d H:i:s foreach ( $leads as $lead ) { GFCommon::log_debug( __METHOD__ … Read more

populating a form field with output from a custom plugin function

You can pre-populate a field with gform_field_value_$parameter_name hook, where $parameter_name is the name of the field/parameter. So, for example if you added that to your code: add_filter(‘gform_field_value_invoice_numb’, ‘my_func’); function my_func( $value ) { return do_shortcode(‘[ABC_form_number length=”13″ char=”num” case=”false”]’); } (Note: Allow field to be populated dynamically option needs to be enabled)

Hata!: SQLSTATE[HY000] [1045] Access denied for user 'divattrend_liink'@'localhost' (using password: YES)