The easiest solution is going to be to turn AJAX on where you are calling the form. If you call the form with AJAX then it's not going to refresh the page when it submits, which is more ideal for situations like this.
Documentation for embedding a form can be found here:
http://www.gravityhelp.com/documentation/page/Embedding_A_Form
Be sure to look at the function call parameters, you can tell it to display using AJAX with the correct parameters.
Since you are calling the form via the function call and not the shortcode in a page or post you will have to also make sure you are enqueuing the necessary scripts and CSS. To enqueue the necessary scripts and CSS you would use the gravity_form_enqueue_scripts function call documented here:
http://www.gravityhelp.com/documentation/page/Gravity_form_enqueue_scripts
You would place that function call in your themes functions.php, ideally you can wrap it in an if statement checking for the post or page id so it only outputs if it's on the page containing that form... unless of course the form is being output on every page and then it's fine to include it globally.
Posted 13 years ago on Monday July 11, 2011 |
Permalink