I’m using multi-page form with Woocoomerce Gravity Forms Addon, on a Elementor page builder.
I want to prevent the scrolling down of the page when i press any button of the form. This scrolling down happens even if the page is not reloading.
(example: i press the next for the first time and before it goes to the next page of the form it scrolls down the page and after reloads goes again to the first option of the form)
So I’m not using a shortcode to add the form to the page, because I’m using the Woocoomerce Gravity Forms Addon, so the form is embedded in the ‘add to cart widget’.
I’ve tried using the add_filter( 'gform_confirmation_anchor', '__return_false' ); but it did’nt work for me.
From what I’ve read in other posts it can be because of AJAX and i believe that ajax is enable and working in my page, but don’t know how to do to prevent the scrolling down to happen.
the filter didn’t worked for me. I just executed it in my functions.php and still the same scrolling down when i press the buttons.
I believe i have AJAX enable because i have a custom button in the same page that sends to the cart a variation with a 0$ to the cart, through a ajax instruction like this one: $.ajax({ type: "POST", rest of code here} and i have a success response because the button is working.
Is there a way of making sure if ajax is enable on the page?
Also, Is there an alternative to the WooCommerce Gravity Forms Product Add-Ons?
Hi Pedro. I recommend checking with the plugin author to confirm that AJAX is disabled when using that plugin with Gravity Forms. I had heard that it does, but I’m not certain.
If you need assistance with the scrolling issue on your site, please confirm that the problem occurs when using only Gravity Forms and a default theme from Automattic like Twenty Twenty One. If it does, please open a support ticket and include the URL where we can see your form embedded. The conflict test will be the first thing we have you perform if you have not already:
So I’ve confirm that the issue is being caused by WooCommerce Gravity Forms Product Add-Ons.
If i disable the plugin and use a gravity form widget on my page then the scrolling issue disappears (with the filter gform_confirmation_anchor in the functions.php).
Also i can see that ajax is enable because there is no page reloads and i press the next or previous button and no parameter are being added to the url.
But i need that plugin to be able to connect the form with the order creation of woocommerce.
Any ideas that could help me do this connection without using the WooCommerce Gravity Forms Product Add-Ons?