Sunday, November 4, 2012

jquery mobile forms validation

jquery mobile forms validation
http://stackoverflow.com/questions/5636856/jqm-jquerymobile-html5-form-validation
http://stackoverflow.com/questions/8997252/jquery-form-validation-in-jquery-mobile
http://www.elijahmanor.com/2011/02/jquery-mobile-form-validation.html





JQM (jQueryMobile) HTML5 Form Validation



Need to add form validation for each form and wanted to take advantage of the html5 syntax, that's why I liked the h5validate plugin but everything I try nothing happens, ugh...
I've also looked at the jQuery Validation plugin but the additional syntax and markup is something I'm trying to avoid. And I've looked at HTML5FORM but it is using jQuery 1.4.2 and I'm using 1.5.x
Wanted to know if anyone else had any luck with html5 and multi form validation submission?




A.

I have had success with multi forms with the validationEngine.js plugin from here http://www.position-relative.net/creation/formValidator/
Example here: http://coww.ws/jqmtest/
Hope this helps?

A2.
ValidVal is what I'm going with, it has all the simple syntax and takes advantage of the html5 attributes for validation



I'm trying to use form validation that is working in this example with my jQuery Mobile project:
This example works but uses an older version of jQuery Mobile js and css files. I'm working with the 1.0 release version which appears to have broken this form validation. You can see my updated version at:
You'll notice when you click the Login button you get the alert messages but they are not in red and are in the wrong location compared to the original version.
Can anyone locate what broke the original version and how to restore functionality to new version using jQuery Mobile 1.0?


Try this:




No comments:

Post a Comment