In our experiments with jQuery Mobile, specifically when applying jQuery Mobile to an existing website, we've encountered one error more than any other. That error is the l.data("page") undefined

It appears that, due to the way jQuery Mobile handles page loading (via AJAX), redirects within your code throw a wrench into the works.

For example, if after submitting a form, you automatically redirect the user to a "Thank You" page, jQuery Mobile is unaware of this action and may throw the error above.

One way around this is to avoid the redirect, and simply display a "Thank You" message within your processing script.

To illustrate this in ColdFusion, you would replace the following code:

<cflocation url="thank-you.cfm">

with

<p>Thank you for your request.</p>
<a href="/">Return Home</a>

Which allows jQuery Mobile to continue loading pages via AJAX.

Tags:

1 Comment

Leave a Reply

Your email address will not be published. Required fields are marked *