Multipart form breakpoint skipping

By: shaun haage | Asked: 06/18/2023
ForumsCategory: How-toMultipart form breakpoint skipping
shaun haage asked 10 months ago
Hi There, We are architecting a complex vehicle quotation form. Once the user has completed personal details and basic vehicle details I need to present the user with a decision to either complete their quotation or proceed and complete further details. Can this be done? The initial thought was to present the user the question continue or submit now using and html element. Using JS we would either bypass the rest of the pagebreaks and submit the form or redirect to the next page break to allow them to add the "additional details". Alternatively, I wanted to possibly bind two form together. when the decision is presented to complete their quotation or proceed and complete further details, complete would submit the form or complete further details would asynchronously pass the already completed details to another form to complete "part 2". Is this possible? And how could this be completed? Are there any examples?
1 Answers
Victor Font answered 10 months ago
Your first idea requires complicated coding and a deep reverse engineering of how Formidable manages page submits in a multi-page form. When you load a multipart form, all the form's fields are loaded regardless of what page they're on. The fields that are not being displayed until the next button is clicked have all been converted to hidden fields. When next or previous is clicked, the form fires a submit() event, but not to submit the form entry. The submit processes the next page to display by converting the hidden fields back to the original display form and hiding the fields that were just being displayed. The entry is not submitted until the final submit unless you have save draft enabled and the user is logged into WordPress.
Victor Font replied 10 months ago

As for your second idea, it's the easier approach to implement. When form A is submitted, redirect to Form B, passing all form values as query string parameters. The default values on form B would use the [get param] shortcode, which reads the query string parameters from the form A redirect.

shaun haage replied 10 months ago

You think this might be possible asynchronously without loading a new page or leaving the page.

shaun haage replied 9 months ago

@Victor Font I am a little unfamiliar with formidable, on this multipart form can I pass values to another form asynchornously? alternatively can values from form 1 be sent without parsing them via a query string and possibly retrieving them from a session var. I am a a little concerned passing up to 10 fields via the query string.

Making the Best WordPress Plugin even better - Together

Take on bigger projects with confidence knowing you have access to an entire community of Formidable Experts and Professionals who have your back when the going gets tough. You got this!
Join the community