Vulnerability in EPiServer.Forms
We are using XForms on our Episerver 6 R2 CMS and we were looking to see it is was possible to create a Multi Step Form - like a Wizard where the user sees the first batch of questions and clicks NEXT to go to the next section of the form.
We were thinking of using Classes and JQuery to break the form but thinking it might be a head ache if there was missing validation - how would we display the missing fields and how would the user navigate around the form filling in all the missing fields. Also, it this was at all possible where would the JQuery sit?
The other issue is there are already many forms on the site already so we dont want to mess these up - it has to work as both a Multi and single step update.
I Hope this makes sense.
Please let me know your thoughts and please dont hesitate in saying that this isn't at all possible.
The new Episerver Forms that just came out has a built-in "steps" feature.
Upgrading to CMS 9 just to get the new Forms feature is probably not on the agenda :-)
If your editors have a requirement to be able to build new multi-step wizards themselves, I can (sort of) understand why you'd go with XForms. However, you'll be putting yourself through a world of pain. The times we've built multi-step forms in CMS6, we did them as page templates (not XForms), using either a system of populated placeholders that are shown/hidden depending on the current step, or using a standard ASP control like <asp:wizardstep
In our case, we had several integrations which had to execute and validate on and between form steps, so XForms wasn't the best choice. Then again, once the forms were built, editors couldn't easily change them. Bottom line, Xforms were never meant for multi-step forms - especially whenever integrations are involved.
Benefits of upgrading should be repeated as often as possible :)
And why not also mention just going with Surveymonkey or similar. Not sure which ones can be embedded nicely if that's a requirement though.
Here's a really low-tech suggestion: In the first form (step1), setup the form to redirect to another page on submit (be sure to set the submit button text to "Next" or similar.)
On the second page, place your next form (step2) instead of a thankyou-message like you normally would. Repeat this chain of forms for however many steps you need, which for the user will seem like a wizard-type form.
Yes, you'll end up with a bunch of submitted forms data that you'd have to stitch together afterwards, so it's probably not the most practical approach, but it's an approach that doesn't require heavy customization :-)