WordPress Easy Modal and Gravity Forms

gravity forms and modalIf you are looking to create a modal box on your site with a gravity form, there is one issue we have run into a few times that can cause you a lot of headaches.  The people at Gravity Forms recommend using Easy Modal for modal boxes with WordPress.

In the first instance, we were trying to create a two step gravity form in a modal box trigger by someone asking for a quote.  You might have seen examples like this on many different websites.  The problem was that when you clicked the next button, easy modal would close the window so you never got to see step two.

In the second instance, we were trying to create a simple one page quote form to fill out.  The problem came that if you didn’t enter a field correctly, for example a phone number, the modal box would close.  The user would have no idea if the form actually was submitted or not.  If you clicked the quote box again, the modal reappears and you can see the errors in the gravity.  Most people likely would not do this and think the form was submitted.

After contacting modal forms and trying several ideas, the solution was very simple.  All you need to do is add ajax=true to the shortcode in Gravity Forms Short Code.  This will allow gravity forms to submit, but not close the window.

For example, if your code is
[html][ gravityform id="3" name="Quote Request" title="false" description="false" ]  change the code to: [ gravityform id="3" name="Quote Request" title="false" description="false" ajax=true ] [/html]
and your problem will be solved.

Hopefully this tip will help save you a lot of time and headaches.

Will Facebook ads still be effective in 2023?

By Dave Fogel | December 20, 2022

Yes, We predict Facebook Ads will still be effective in 2023. Facebook has made several changes to its advertising platform since the iOS 14 update that caused them to lose most of its tracking ability when users left the platform.  Long story short, FB could no longer see where users went after they left the…

Why should you use Google Ads?

By Dave Fogel | December 20, 2022

Google Ads is an advertising platform created by Google that allows businesses to reach potential customers and increase their online visibility. It is a powerful tool that can be used to target specific audiences and promote products and services. Google Ads enables businesses to create engaging ads that can be delivered to the right people…

Why Google Ads is better than Facebook Ads

By Dave Fogel | December 19, 2022

Google Ads offers businesses a number of advantages over Facebook Ads. Google Ads allows businesses to target specific locations and audiences, allowing them to reach the people that are most likely to be interested in their services. Additionally, Google Ads offers businesses more control over their campaigns, allowing them to adjust their campaigns in real-time…

Posted in

Dave Fogel

Leave a Comment