gform_zapier_use_stored_body

gform_zapier_use_stored_body

DescriptionUsageParametersExamplesPlacementSinceSource Code

Description
The 「gform_zapier_use_stored_body」 filter is used to determine if the already stored body should be used.
Usage
add_filter( 'gform_zapier_use_stored_body', 'your_function_name', 10, 4 );

Parameters

$use_body bool
If the current body should be used. Defaults to true.

$entry Entry Object
The current entry.

$form Form Object
The form object.

$feed Feed Object
The feed object.

Examples
add_filter( 'gform_zapier_use_stored_body', 'use_body', 10, 4 );
function use_body( $use_body, $entry, $form, $feed ){
return false;
}

Placement
This code should be placed in the functions.php file of your active theme.
Since
This filter was added in Gravity Forms Zapier version 2.1.1.
Source Code
This filter is located in GFZapier::get_body() in zapier.php.

Help Scout Change Log

Help Scout Change Log

2.0 | 2021-05-061.15 | 2020-09-281.14 | 2020-07-141.13 | 2020-05-181.12.41.12.31.12.21.12.11.12 | 2019-11-061.11 | 2019-10-031.10 | 2019-10-021.9 | 2019-08-071.8 | 2019-07-241.7 | 2019-06-111.6 | 2019-06-031.5 | 2018-04-031.4 | 2017-01-051.3 | 2016-01-111.2 | 2015-06-291.1 | 2015-06-111.0 | 2015-05-27

2.0 | 2021-05-06

Added a form settings menu icon for Gravity Forms 2.5

1.15 | 2020-09-28

Updated support for Gravity Forms 2.5.
Fixed a PHP notice which occurs when after authenticating Help Scout account.

1.14 | 2020-07-14

Added security enhancements.
Updated the get conversation requests for the entries list and detail pages to cache the conversations for one hour to reduce the number of requests to the Help Scout API.
Updated the Assignee setting so the choices are arranged into Teams and Users optgroups.
Fixed a performance issue with the link in the Conversation ID column of the entries list page which caused a 500 error on some hosting environments.
Fixed the Destination Mailbox setting only listing the first 50 mailboxes.

1.13 | 2020-05-18

Added license key to GF authorization URL.
Added support for Gravity Forms 2.5.
Added the "Click here to refresh access token" button to the add-on settings page so the request can be attempted again when it times out.
Added translations for Hebrew, Hindi, Japanese, and Turkish.
Updated Gravity API domain.
Updated logging statements to clarify that the add-on is still connected to Help Scout when the token refresh times out.
Fixed an issue where HTML encoded characters could appear in conversation tags when displayed in Help Scout.
Fixed an issue where some existing customer details could be lost when the first and/or last name are updated.

1.12.4

Fixed an issue where HTML encoded characters could appear in conversation tags when displayed in Help Scout.

1.12.3

Updated Gravity API domain.

1.12.2

Added license key to GF authorization URL.
Fixed an issue where some existing customer details could be lost when the first and/or last name are updated.

1.12.1

Added the "Click here to refresh access token" button to the add-on settings page so the request can be attempted again when it times out.
Updated logging statements to clarify that the add-on is still connected to Help Scout when the token refresh times out.

1.12 | 2019-11-06

Updated authentication logging statements.
Updated Javascript files, stylesheets to use minified versions.
Fixed auth token refresh failing when the add-on is using a custom app.

1.11 | 2019-10-03

Fixed conversation creation failing when the last name is not provided for a new customer.

1.10 | 2019-10-02

Fixed conversation creation failing when a file attachment exceeds the maximum size allowed by the Help Scout API (10 MB).
Fixed conversation creation failing when the authenticated user does not have permission to access the mailbox where the customer already exists.
Fixed conversation creation failing when merge tags used in the tags setting are for fields without values.
Fixed conversation creation failing when the assigned user has been deleted from the Help Scout account.

1.9 | 2019-08-07

Added security enhancements.
Updated the minimum required Gravity Forms version to 2.1.
Fixed conversations with attachments not being created on servers where allow_url_fopen is disabled.

1.8 | 2019-07-24

Added security enhancements.
Added the Help Scout Conversation Created notification event.
Added the {helpscout:[prop]}(https://docs.gravityforms.com/helpscoutprop-merge-tag/) merge tag for use in notifications sent after the conversation has been created. Supported properties are id, number, status, subject, and url.
Fixed a fatal error which can occur during feed processing if the get or create customer requests experience an issue.
Fixed the BCC email addresses not being added to the conversation.
Updated error logging statements.
Updated the feed settings so mapping the customer first name field is required.

1.7 | 2019-06-11

Fixed uploaded files not being attached to conversations.

1.6 | 2019-06-03

Added gform_helpscout_conversation filter to allow modifying the conversation before it is created in Help Scout.
Added support for updating first name and last name and adding new phone numbers when user with matching email is found in Help Scout.
Updated to use Help Scout's Mailbox API 2.0.
Fixed issue where authenticating with Help Scout via Gravity API was not working.
Fixed the conversation status changing from closed to active when adding a note.

1.5 | 2018-04-03

Added security enhancements.
Added GPL to plugin header.
Added support for mapping customer phone number.
Added create conversation bulk action to entry list.
Added the gform_helpscout_process_note_shortcodes filter for enabling the processing of shortcodes placed in the note.
Updated Plugin URI and Author URI to use https.
Fixed conversations not creating when CC is enabled but value is empty.

1.4 | 2017-01-05

Added support for the Gravity Forms 2.0 entry detail page changes.
Updated strings for translations.
Updated API library to latest version.
Fixed an issue with the conversation BCC emails not being set correctly.
Fixed conversation not being created if first or last name was longer than forty characters.

1.3 | 2016-01-11

Added checkbox to add entry note form to post note to Help Scout conversation.
Added feed duplication support.
Added feed setting to create note for conversation.
Added panel to entry view page with Help Scout conversation details.
Added support for delaying feed processing until payment by PayPal Standard is successfully completed.
Enabled single feed submission.
Fixed an issue with the helpscout_conversation_id entry meta property so it's returned with the entry object.
Fixed an issue with the feed settings page and the conditional logic setting.
Fixed an issue where HTML entities would appear in conversation subject when using merge tags.
Fixed an issue where Help Scout would not include the conversation in the mailbox folder counts.
Fixed an issue where multi-file upload field attachments would not upload correctly.
Updated "Help Scout Conversation ID" entry list column to link to Help Scout conversation.
Updated feed processing to prevent multiple Help Scout conversations from being created.
Updated to store the created conversation id in the entry meta using the key 'helpscout_conversation_id'.
Updated the form field drop down for the Customer's Email Address to include hidden fields.

1.2 | 2015-06-29

Added support for auto replies when conversation is created
Added the gform_helpscout_process_body_shortcodes filter for enabling the processing of shortcodes placed in the message body.
Fixed an issue with conversations being tagged as 'Untagged'.
Updated several functions to use new Add-On Framework functionality.
Updated feed processing to abort if value of mapped Email Address field is invalid or empty.

1.1 | 2015-06-11

Added gf_helpscout() for easily getting an Help Scout instance.
Added additional logging statement to process_feed().
Added Spanish (es_ES) translation.
Fixed tags not being appropriately added to conversations.
Fixed PHP warning when no file attachments were provided.
Fixed Add-On not loading if Help Scout API class was already defined.

1.0 | 2015-05-27

It's all new!

GFStripe

GFStripe

Descriptiongf_stripe()get_payment_feed()cancel()get_amount_export()get_amount_import()insert_feed()add_note()log_debug()log_error()include_stripe_api()

Description
GFStripe is the class which houses the main functionality of the Gravity Forms Stripe Add-on; it extends the GFPaymentAddOn class which is part of the add-on framework. Below are a few functions which you may find useful when working on your own custom code.
gf_stripe()
The gf_stripe() function is used to return an instance of the GFStripe class.
get_payment_feed()
Retrieves the feed used to process the entry object. If the Form Object is supplied and an Entry Object isn』t then the first active feed which matches conditional logic will be returned.
1$feed = gf_stripe()->get_payment_feed( $entry );

$entry Entry Object | boolean
The Entry Object to be checked.

$form Form Object | boolean
The Form Object to be used when evaluating feed conditional logic. Defaults to false.

Returns Feed Object | boolean
The feed for this entry or false.

cancel()
Cancel the Stripe subscription for the customer who was created from the supplied Entry Object.
1$result = gf_stripe()->cancel( $entry, $feed );

$entry Entry Object
The Entry Object the subscription/customer was created from.

$feed Feed Object
The Feed Object. Not currently used so you could pass false instead.

Returns boolean
True or false. Indicates if the subscription cancellation was successful.

get_amount_export()
Removes currency symbol and if required converts the amount to the smallest unit required by the gateway (e.g. dollars to cents).
1$amount = gf_stripe()->get_amount_export( $amount, $currency_code );

$amount integer | float
The value to be formatted.

$currency_code string
The currency code.

Returns integer | float
The value which can be safely passed to Stripe.

get_amount_import()
If necessary convert the amount back from the smallest unit required by the gateway, e.g. cents to dollars.
1$amount = gf_stripe()->get_amount_import( $amount, $currency_code );

$amount integer | float
The value to be formatted.

$currency_code string
The currency code.

Returns integer | float
The formatted value.

insert_feed()
The insert_feed() method can be used to add Stripe feeds.
1$feed_id = gf_stripe()->insert_feed( $form_id, $is_active, $meta );

$form_id integer
The ID of the form this feed will be used with.

$is_active boolean
Is this feed active or inactive.

$meta Stripe Feed Meta
An associative array containing the properties which determine the type of transaction which will occur when the feed is processed.

Returns integer
The ID of the new feed.

add_note()
Add a note to the specified Entry.
1gf_stripe()->add_note( $entry_id, $note, $note_type );

$entry_id integer
The ID of the Entry this note should be added to.

$note string
The note to be added.

$note_type string
The type of note to be added. Example values: note, success, or error.

log_debug()
Writes a debug message to the log file for the Stripe Add-On. Requires the Logging Add-On.
1gf_stripe()->log_debug( $message );

$message string
The message to be written to the Stripe log.

log_error()
Writes an error message to the log file for the Stripe Add-On. Requires the Logging Add-On.
1gf_stripe()->log_error( $message );

$message string
The message to be written to the Stripe log.

include_stripe_api()
Include the Stripe API.
1gf_stripe()->include_stripe_api();

Gravity Forms Pricing: Adding Tax

Gravity Forms Pricing: Adding Tax

Using A Calculation FieldThird Party PossibilitiesGravityWiz Subtotal Merge Tag (for Calculations)Gravity Perks eCommerce Fields

Using A Calculation Field
If you would like to implement tax you can use the Product Field configured as a Calculation field type. Then configure the formula for the calculation to calculate the appropriate tax.
You would do this by adding up the value of all of the Pricing Fields that exist on your form, and then multiply them by the appropriate tax rate.
If tax should only be applied in certain situations, you can then use conditional logic to show or hide that field based on the conditions that must exist in order for the tax to be applied.
Third Party Possibilities
Here are a couple of third party options to make this process easier, or possibly suite more use cases:
GravityWiz Subtotal Merge Tag (for Calculations)
Snippet that offers a merge tag called {subtotal}, for calculating the subtotal of all your product and option fields without having to manually enter these yourself. A 10% tax could then be calculated like so: {subtotal} * 0.1
Gravity Perks eCommerce Fields
Adds pricing fields like Discount, Tax, and Subtotal. Also adds special merge tags for including the subtotal, coupon and discount amounts in calculation-enabled fields.

gform_zohocrm_post_create_lead

gform_zohocrm_post_create_lead

DescriptionUsageParametersExampleSinceSource Code

Description
Allows custom actions to be performed after creating a lead with a Zoho CRM feed.
Usage
add_action( 'gform_zohocrm_post_create_lead', 'action_after_lead_creation', 10, 5 );
function action_after_lead_creation( $lead_record, $lead, $feed, $entry, $form ) {
// Do your stuff
}

Parameters

$lead_record array

The response from Zoho CRM after a feed has successfully created a lead, with the lead id injected.
Sample array:
array
(
'code' => 'SUCCESS'
'duplicate_field' => ''
'action' => 'insert'
'details' => array
(
'Modified_Time' => '2019-08-08T12:15:47-07:00' //System-generated modification timestamp
'Modified_By' => array // Name and ID of the user who modified the lead.
(
'name' => 'Silvia Samples'
'id' => 3451042000000292017
)

'Created_Time' => '2019-08-08T12:15:47-07:00' // System-generated creation timestamp.
'id' => 3351042000000745001 // Unique ID of the lead
'Created_By' => array // Name and ID of the user who created the lead.
(
'name' => 'Silvia Samples'
'id' => 3451042000000292017
)

)

'message' => 'record added'
'status' => 'success'
)

$lead array
The lead arguments that you sent to Zoho CRM to initiate the creation process. It includes entry fields as per your Zoho feed field mappings, and the feed options you have set.

A sample array may be:
array
(
'Email_Opt_Out' => '' //feed setting
'Description' => '' //Lead description, as per Zoho definitions.
'Lead_Source' => 'Partner' //Source from which the lead was created, as per Zoho definitions.
'Lead_Status' => 'Rating' => 'Contact in Future' //Status of the lead, as per Zoho definitions.
'Rating' => 'Contact in Future' //The rating of the lead, as per Zoho definitions.

'options' => 'array
(
'duplicateCheck' => 1 //value of 1 or 2. See note below.
'isApproval' => '' //the Approval Mode from the feed settings
'wfTrigger' => '' //the Workflow Mode from the feed settings
)

// Fields that have been mapped in the Zoho feed, and their values collected from the entry.
'Company' => 'Sample Company'
'Email' => '[email protected]'
'First_Name' => 'Silvia'
'Last_Name' => 'Samples'
)

Note regarding duplicateCheck:
duplicateCheck value of 1 is equivalent to the feed options of Update Contact If Already Exists = false, and Allow Duplicate = false. That is, feed will only create contact if it does not exist already.
duplicateCheck value of 2 is equivalent to the feed options of Update Contact If Already Exists = true, and Allow Duplicate = false. That is, feed will update a matching contact if it exists already.

$feed array
The feed object.

$entry array
The entry object.

$form array
The form object.

Example
The following example will send a notification after the lead creation. The notification must be configured to use a custom notification event already registered using gform_notification_events filter.
add_action( 'gform_zohocrm_post_create_lead', 'send_notification_after_lead', 10, 5 );
function send_notification_after_lead( $lead_record, $lead, $feed, $entry, $form ) {
// Send a notification configured to use the custom Event zoho_lead
GFAPI::send_notifications( $form, $entry, 'zoho_lead' );
}

Since
This filter was added in Zoho CRM version 1.8.
Source Code
This filter is located in class-gf-zohocrm.php.

Gravity Forms 2.5 Known Limitations

Gravity Forms 2.5 Known Limitations

IntroductionKnown Changes & LimitationsJavascriptForm EditorColumnsTranslationsMobile DisplayAdd-OnsDeprecated ItemsFiltersAdd-On Framework ChangesFound Something Not Listed Here?

Introduction

This document details some changes to existing behavior in Gravity Forms 2.5 that may affect existing setups or behaviors, or might require changes to your site. These compromises are deliberate, and are not targeted for change unless identified otherwise.

Known Changes & Limitations

Javascript

Javascript is moved to the footer by default in Gravity Forms 2.5. Custom approaches that move Gravity Forms scripts to the footer themselves will no longer work and will need to be removed.

Form Editor

The form editor is designed to be used on desktop and is designed for or supported on mobile devices.

Internet Explorer 11 (IE 11) is not supported for the Form Editor. It is not possible to edit label placement inside the layout editor—this can only be done in the settings.The gf_inline and the column ready classes are not supported in the new markup. This is superseded by the ability to drag & drop the fields columns directly using the editor.When conditional logic is configured to 「hide」 a form button, the button is not removed from the page as previously was the case, but disabled instead. Leaving it visible but inactive is a change made in support of improved accessibility.The Credit Card Field no longer has a Card Icon Style setting.

Columns

There is a maximum of 4 resizable columns. You cannot create a fifth.Columns are not supported on forms with legacy markup enabled. Disable legacy markup in the form settings to use the columns.The field types of Page, Section & Hidden cannot be placed in columns.

Translations

The datepicker is now translated automatically. The previous snippet that was used to load custom datepicker translations must be removed.A few strings may still need to be made translatable. This will be addressed in an upcoming patch.

Mobile Display

The form list toolbar and entry list filtering need to be updated to look correct on mobile devices. This will be addressed in an upcoming patch.

Add-Ons

Processing of BuddyPress field mappings for the User Registration add-on is not currently supported. Fixed in User Registration v4.8.

Deprecated Items

Filters

gform_notification_validation filter has been removed.

Add-On Framework Changes

The following methods have been deprecated, and will return null due to no action being taken.

GFAddOn::maybe_save_form_settings()GFAddOn::maybe_save_plugin_settings()

Found Something Not Listed Here?

Contact our Customer Support team here.

gform_zoho_accounts_api_url

gform_zoho_accounts_api_url

DescriptionUsageParametersExamplesPlacementSinceSource Code

Description
The 「gform_zoho_accounts_api_url」 filter allows the Zoho CRM accounts API URL to be changed. This is useful because, in addition to crm.zoho.com, Zoho CRM has a European solution that points to crm.zoho.eu.
Usage
1add_filter( 'gform_zoho_accounts_api_url', 'your_function_name', 10, 1 );

Parameters

$accounts_api_url string
Zoho CRM accounts API URL.

Examples
1234add_filter( 'gform_zoho_accounts_api_url', 'change_zoho_accounts_api_url', 10, 1 );function change_zoho_accounts_api_url( $accounts_api_url ){    return "https://accounts.zoho.eu";}
Placement
This code should be placed in the functions.php file of your active theme.
Since
This filter was added in Zoho CRM version 1.2.5.
Source Code
This filter is located in GFZohoCRM::get_accounts_api_url() in gravityformszohocrm/class-gf-zohocrm.php.

Help Scout Feed Meta

Help Scout Feed Meta

IntroductionUsageProperties

Introduction
The Feed Object meta for the Help Scout add-on is an associative array containing the properties which determine how the add-on should process the form submission.
$feed['meta'] = array(
'feed_name' => 'Your Feed Name',
'feed_condition_conditional_logic' => true,
'feed_condition_conditional_logic_object' => array(
'conditionalLogic' => array(),
),
);

Usage
We recommend accessing the $feed meta using the rgar() or rgars() functions, e.g.:
$conditional_logic_enabled = rgars( $feed, 'meta/feed_condition_conditional_logic' );

Properties

feed_name string
The feed name which appears on the add-ons feeds tab.

mailbox string
The Help Scout ID of the Mailbox the conversation will be added to.

user string
The Help Scout ID of the User the conversation should be assigned to.

status string
The conversation status. Possible values: active, pending, closed or spam.

type string
The conversation type. Possible values: email, chat or phone.

customer_email string
The ID of the field containing the customer』s email address.

customer_first_name string
The ID of the field containing the customer』s first name.

customer_last_name string
The ID of the field containing the customer』s last name.

tags string
A comma separated string containing the tags the conversation should be assigned. Merge tags are supported.

subject string
The conversation subject line. Merge tags are supported.

body string
The conversation message. Merge tags are supported.

attachments array
array(
'10' => true,
'11' => false,
);

An array of file upload fields. The field ID is the key with a boolean value indicating if the files for that field should be attached.

cc string
A comma separated string containing the emails the conversation should be cc』d to. Merge tags are supported.

bcc string
A comma separated string containing the emails the conversation should be bcc』d to. Merge tags are supported.

auto_reply boolean
Should Help Scout send an auto reply when the message is created. Default false. Added in Help Scout 1.2.

feed_condition_conditional_logic boolean
Is the feed condition (conditional logic) setting enabled. Default is false.

feed_condition_conditional_logic_object array
An associative array containing the conditional logic rules. See the Conditional Logic Object for more details.

gquiz_answer_indicator

gquiz_answer_indicator

DescriptionUsageParametersExamplesPlacementSource Code

Description
This filter allows the HTML markup for the answer indicator to be changed.
Usage
add_filter( 'gquiz_answer_indicator', 'gquiz_answer_indicator', 10, 7 );

Parameters

$indicator_markup string
The indicator HTML/text for an answer.

$form Form Object
The form object.

$field Field Object
The field object.

$choice
The Choice object for the quiz.

$lead Lead Object
The Lead object.

$is_response_correct bool
True or false if the response is correct; can be used to change indicators.

$is_response_wrong bool
True or false if the response is incorrect; can be used to change indicators.

Examples
add_filter( 'gquiz_answer_indicator', 'gquiz_answer_indicator', 10, 7);
function gquiz_answer_indicator( $indicator_markup, $form, $field, $choice, $lead, $is_response_correct, $is_response_wrong ) {
if ( $is_response_correct ) {
$indicator_markup = ' (you got this one right!)';
} elseif ( $is_response_wrong ) {
if ( $field['inputType'] == 'checkbox' && rgar( $choice, 'gquizIsCorrect' ) ) {
$indicator_markup = ' (you missed this one!)';
} else {
$indicator_markup = ' (you got this one wrong!)';
}
} elseif ( rgar( $choice, 'gquizIsCorrect' ) ) {
$indicator_markup = ' (this was the correct answer!)';
}
return $indicator_markup;
}

Placement
This code should be placed in the functions.php file of your active theme.
Source Code
This filter is located in GFQuiz::get_quiz_results() in gravityformsquiz/class-gf-quiz.php.

Gravity Forms System Requirements

Gravity Forms System Requirements

Preferred System RequirementsSupport RequirementsOlder EnvironmentsPHPChecking For Compatibility Within Gravity Forms

Preferred System Requirements
For the best performance of Gravity Forms, we recommend the latest production version of WordPress. Thus your Gravity Forms environment should utilize the same system requirements as WordPress itself.

click to view the WordPress system requirements.
click to check the latest version of WordPress

Support Requirements
To receive support, we expect your Gravity Forms solution to be running the current or previous version of WordPress. For example, if WordPress 5.6 is the current version, then we offer support for environments running WP 5.6 and WP 5.5.
Refer to this 2013 blog post from our CEO for more context on this.
Older Environments
Gravity Forms may also work with some older versions of PHP and MySQL. Gravity Forms and official Gravity Forms Add-On new versions are not tested with with unsupported versions of those frameworks or WordPress. Additionally, older versions may expose your site to security vulnerabilities. See our article about the importance of updates.
Additionally, older versions may not meet the support requirements as listed above. If you reach out for support, you may be required to upgrade before you can gain assistance.
We highly recommend contacting your host to upgrade to the Preferred System Requirements..
PHP
If your PHP version is not listed on the php.net supported versions page you (or your web host) should update immediately.
Also, please see this active 2021 bulletin regarding PHP 8.0 compatibility
Checking For Compatibility Within Gravity Forms
A lot of environment information can be found within your System Status page, found under the Forms menu item in the admin area. See this article for more information.