Project strategy - Add a form to multiple web pages

By: Shelon pounds | Asked: 01/08/2024
ForumsCategory: General questionsProject strategy - Add a form to multiple web pages
Shelon pounds asked 12 months ago

[edited for clarity and added a missing option]

I'm looking for some help on the best way to structure my form(s) and web pages. I'm creating multiple web pages in an online course that each contain instructions and a video.  I want to embed a form onto each page.  The form(s) will collect information, some of which will flow to the following form(s).  There will be 60+ fields per page.  The web pages and the forms they contain will be viewed in succession and the navigation buttons on each page/form will point to the next and previous web page. Here are the options I've considered...

  1. a single-page form on each web page.  the submit button for each form navigates to the URL of the next web page.  all of the form data would need to transfer to the next form.
  2. a multi-page form with a specific page of the form that displays on each web page.  so page 1 of the form would display on the first web page.  when you click Next you go to the second web page and page 2 or the form is displayed, etc. 
  3. i thought about adding the instructions and video to each page of a multi-page form, but that seems like it would interfere with the course progression.  each web page and form is intended to represent a separate step of the course (and be shown as such in the course progression panel).
  4. maybe there's another option I'm not thinking of

I've searched but don't see this sort of use case talked about.  Any push in the right direction would be much appreciated.  I prefer to use built-in functionality and jQuery but not custom PHP if possible.

1 Answers
Rob LeVineRob LeVine answered 12 months ago
Maybe I'm simplifying this, however, isn't a multi-page form exactly what you want? I know it's your option #2 so I'm wondering if you're not sure that's natively available in FF.
Shelon pounds replied 12 months ago

<p>Thanks for your reply Rob.</p><p>If I had 1 web page and wanted to embed a multi-page form, then the way is clear. However, for my situation I have multiple web pages and I would like to have different pages of the multi-page form appear on each web page. So for example, on web page A there would be page 1 of the form, when you click the Next button you're taken to web page B where page 2 of the form is displayed, etc. If a multi-page form is the way to go for my use case, then I'm looking for some direction on how to get the specific functionality I need.  More specifically, how to get the Next button to submit the info on the form and take me to a new URL where the next page of the form is displayed instead of displaying the next page of the form while staying on the same web page.</p>

Rob LeVineRob LeVine replied 12 months ago

Ah OK, thanks for clarifying (though you probably were clear in your original message as well). I can think of ways to handle this using jQuery (maybe more than you want to do). I'm also wondering if you have a hidden field "pageNum" and fill it in as you move from page to page, you could use conditional logic in the form to hide/show the fields for that page. You might also be able to use either the Redirect feature on submitting (https://formidableforms.com/knowledgebase/general-form-settings/#kb-on-submit) to send to another page based on which page you're on (or you can use the javascript alternative to that (https://formidableforms.com/knowledgebase/javascript-examples/javascript-after-form-submit/)

Shelon pounds replied 12 months ago

Thanks for you continued help with this

>I can think of ways to handle this using jQuery (maybe more than you want to do).
I'm ok using jQuery. I've used it for a previous project to do calculations, hide fields, etc., but I haven't figured out how to get it to work for this specific issue

>I'm also wondering if you have a hidden field "pageNum" and fill it in as you move from page to page
I'm able to display a specific page of the multi-page form by putting 'page=x' in the embed code for the web page. It's getting the Next button on page 1 of the form to take me to web page B (that contains page 2 of the form) that I'm not able to get to work

>You might also be able to use either the Redirect feature on submitting
I've gotten this to work for a single-page form as the Submit button is the only button. But for a multi-page form I'm essentially needing the Next button for a form page to have the same functionality as the Submit button. I don't want to click Next to go through the form pages and then click Submit on the last form page and have it redirect me to a new web page. I want the Next button to redirect me to a new web page.

Please let me know if I'm missing something about how the options you mentioned work.

Rob LeVineRob LeVine replied 12 months ago

I guess my comment for the three options is the same. My "solution" was that the jQuery would take over a lot of it, especially the navigation and the hide/show. I just had another thinking-outside-the-box idea. What if you had X+1 forms, where X is the total number of pages you have? The +1 is the "real form", meaning that when you submit forms 1..X, you push the data into the "real form". So when you're all said and done, all the data is in one place and all the pages each have one form. This might be insane (and could potentially be nightmarish if you allow users to update their entries). I hope someone else answers :). Have you filed a support request with S11/Formidable?

Shelon pounds replied 12 months ago

Thanks for continuing to help me think through this.

For the option to use multiple single-page forms (either as I described in option #1 above or as you described with multiple forms that feed into a single 'master' form), I think I mostly have the know-how to do it. The navigation is easy as a redirect URL can be added in the settings for each form (confirmation form action) so the Submit button for each form takes me to the next web page. However, I'm wondering if the data manipulation (copying fields, calculations, etc) as well as custom jQuery/javascript code would be more cumbersome using this method. I'm new to this stuff, so I was hoping to have someone with more experience that could advise on the strength of this approach.

For the option to use a multi-page form where each page of the form appears on a different web page (my option #2 above), it seems to me that this simplifies things as all of my custom code is in the same place and I think the data manipulation might be more straight forward. My sticking point for this method is the navigation. Since each form page (except for the last page) has a Next button instead of a Submit button, I would need to figure out how to get the Next button to redirect to a URL as this doesn't seem to be a built-in option as it is for the Submit button. Maybe I should just focus on figuring out this navigation issue and move forward with this option? I was just trying to zoom out to see if this is the preferred approach before spending too much time in this direction.

I thought this forum was the place for these types of questions so I haven't created a support request. Maybe I should?

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
crossarrow-right