...

JQuery mobile: multi-page form

I have a mobile jquery form that is wrapped around two pages:

<form ...> <div data-role="page"> ... </div> <div data-role="page"> ... </div> </form> 

It works very well when this page loads through a browser.

However, when the page is called via Ajax, as you would expect, the form tag is not imported into dom, so the form is broken.

Is there any solution besides rewriting the hole stream?

Thanks!

Edit: I would like to keep the ajax navigation, I know I can fix it just by calling this w / out ajax page.

+4
source share
2 answers

I finally managed to do it differently because there was no easy way to achieve this ...

-1
source

You can serialize the form data and save it as a local var until the last step / page. This is very well described on this page: http://www.raymondcamden.com/index.cfm/2011/11/22/Demo-of-a-multistep-form-in-jQuery-Mobile-Part-2

Hooray!

0
source