• Home
  • Pricing
  • Free Resources
  • About
  • Docs
  • Support
  • Account

Gravity Wiz

Magically enhanced tutorials, snippets and plugins for Gravity Forms!

  • Gravity Perks
    • Gravity Perks
    • Pricing
  • Blog
    • Free Resources
    • About
  • Support
    • Docs
    • Support
    • Account

gppt_script_args

  1. Description
  2. Usage
    1. Apply to All Forms
    2. Apply to Specific Form (by form ID)
  3. Parameters
    1. Full $args Properties
  4. Source Code
  5. Since

Description

Filter all of the properties that will be used to initialize the GP Page Transitions JS functionality.

Usage

Apply to All Forms

add_filter( 'gppt_script_args', 'your_function_name', 10, 3 );

Apply to Specific Form (by form ID)

// format: gppt_script_args_{formId}
add_filter( 'gppt_script_args_7', 'your_function_name', 10, 3 );

Parameters

  • $args array

    An array of properties that will be used to initialize the GP Page Transitions JS functionality. See $args section below for a full list of $args properties.

  • $form Form object

    The current form object.


Full $args Properties

  • formId int

    Current form ID.

  • enablePageTransitions bool

    Flag indicating whether page transitions are enabled.

  • enableAutoProgress bool

    Flag indicating whether auto-progression is enabled.

  • hideNextButton bool

    Flag indicating whether next button should be hidden.

  • hidePrevButton bool

    Flag indicating whether previous button should be hidden.

  • enableSoftValidation bool

    Flag indicating whether soft validation is enabled.

  • validationSelectors array [ {

    An array of validation selector objects which control which inputs are validated and how.

    • id int

      Field ID of the selector.

    • selectors array

      An array of selector strings (i.e. ‘#input_1_2’).

    • relation string

      Specifies how the validation should be applied. Should ‘all’ selectors have a value or does validation pass if ‘any’ selector has a value?

    • validationMessage string

      Message to be displayed if field fails validation.

    } ]

  • validationClass string

    Class(es) to be applied to the field container when a field fails validation.

  • validationMessageContainer string

    Markup that will wrap the validation message. Must include “{0}” wherever the message should be included in the markup.

  • submission array {

    The result of the submission. Used to reset the state of the GPPageTransitions JS object after a submission.

    • hasError bool

      Flag indicating whether the submission has an error.

    • sourcePage int

      Page number from which the form was submitted.

    • errorPage int

      Page number on which the first field with an error resides.

    }

  • pagination array {

    An array of properties specific to how the form’s pagination is configured.

    • type string

      The pagination type of the current form.

    • startAtZero bool

      Flag indicating whether or not the progress bar should start at zero and only show 100% on the confirmation page.

    • pageCount int

      The total number of pages on the current form.

    • progressIndicators array

      An array of the progress indicator markup (progress bar or steps) for each page of the form. This is only used if ‘gppt_is_custom_pagination’ filter is configured to return true.

    • pages array

      An array of page names specified for the current form.

    • isCustom bool

      Flag indicating whether or not the progress indicators are custom or standard.

    • labels array

      An array of labels used to recreate Gravity Forms’ standard page verbiage.

    }

  • transitionSettings array {

    An array of properties specific to the transition script. See Cycle options for a full list of all options that can be specified here. http://jquery.malsup.com/cycle/options.html

    • fx string

      The transition effect used to transitions pages. Defaults to ‘scrollHorz’.

    • easing string

      Specifies how the transition effect should be applied. Defaults to ‘easeInOutBack’ if transition is set to “Slide” or null for “Fade”.

    • sync bool

      Flag indicating whether the transition of the next page should happen at the same time as the current page is transition out. Defaults to false for “Fade”, true for “Slide”.

    • speed int

      Specifies the speed at which the transition should be applied.

    • timeout int

      Set to 0 to disable automatic transitions. Note: this does not relate to the Auto-progression feature.

    • containerResize bool

      Flag indicating whether or not to resize the container to fit the largest page when the script is initialized. Defaults to false.

    • slideResize bool

      Flag indicating whether or not to force pages to specific size before each transition.

    }

Source Code

This filter is located in GP_Page_Transitions::pre_render() in class-gp-page-transitions.php.

Since

This filter is available since GP Page Transitions 1.0.

All Perks

  • GF Address Autocomplete
  • GF Advanced Calculations
  • GF Advanced Phone Field
  • GF Advanced Save & Continue
  • GF Auto List Field
  • GF Auto Login
  • GF Better User Activation
  • GF Blocklist
  • GF Conditional Logic Dates
  • GF Conditional Pricing
  • GF Copy Cat
  • GF Date Time Calculator
  • GF Disable Entry Creation
  • GF Easy Passthrough
  • GF eCommerce Fields
  • GF Email Users
  • GF Entry Blocks
  • GF Expand Textareas
  • GF File Renamer
  • GF File Upload Pro
  • GF Google Sheets
  • GF Inventory
  • GF Limit Checkboxes
  • GF Limit Choices
  • GF Limit Dates
  • GF Limit Submissions
  • GF Live Preview
  • GF Media Library
  • GF Multi-Page Navigation
  • GF Nested Forms
  • GF Notification Scheduler
  • GF Page Transitions
  • GF Pay Per Word
  • GF PayPal One-time Fee
  • GF Placeholder
  • GF Populate Anything
  • GF Post Content Merge Tags
  • GF Preview Submission
  • GF Price Range
  • GF QR Code
  • GF Randomizer
  • GF Read Only
  • GF Reload Form
  • GF Terms Of Service
  • GF Unique ID
  • GF Word Count

Copyright © 2023 · Powered by WordPress · Gravity Wiz LLC

  • Support
  • Affiliates
  • About
  • Sitemap
  • Terms & Conditions of Use
  • Privacy Policy
  • Cookies Policy