What Is The Best Way To Place 2 Forms On The Same Page?
What is the best way to place 2 identical forms on the same page, but use the same form action and fields for each form? How can I keep response messages in the respective form area from which the data was submitted?
I'd have one form in the footer of my site, and one form in a popup on the home page of my site. I'm using a hidden div and Magnific to open the popup containing the same code from the form that is located at the footer. Essentially, both form do the same thing, and utilize the same form action.
I do not have access to the form action, or the code in the form action page.
Currently, the forms existing on the same "page" are no problem, but when I submit an email on one form, the errors and success messages show up on both the popup form as well as in the footer form.
I've read that this may be possible to do with ajax, but for completeness sake, I want to make sure that I'm building that I'm doing what I can with the form html, before moving on to studying ajax for this.
Sadly there is no nice html/liquid solution for this.
AJAX is not a good solution because of the Google Recaptch-a when you submit the form more than once, which is a real pain in the a** since there is no way to disable it and the form will fail if you try to submit it with ajax.
Forms in Shopify are... how to put it nicely... dumb... basic... not developer friendly or just not made to be tweaked in any sort of way ( excluding the front-end ).
- → How to update data attribute on Ajax complete
- → October CMS - Radio Button Ajax Click Twice in a Row Causes Content to disappear
- → Passing a JS var from AJAX response to Twig
- → when i send data with ajax(jquery) i don't find the values in controller without form in laravel 5.1
- → Uncaught TypeError Illegal invocation when send FormData to ajax
- → Sent Variable to Controller via Ajax in Blade
- → AJAX folder path issue
- → KNockout JS - Automatic reload of ajax call
- → Upload file with iron-ajax (Google Polymer)
- → Drag and Drop(event) not trigger ajax POST
- → Insert values from FORM to DB using AJAX on october cmd
- → 500 Internal Server Error Ajax Laravel
- → Repeating a function using array of values