Hello -
Ihave a JQuery dialog box
- <div data-role="content" data-theme="a">
- <form id="myform" action="" method="post" data-ajax="false">
- <fieldset data-role="controlgroup" data-type="verticle">
- <label for="name">Name: </label><input type="text" name="name" />
- <label for="tel">Telephone: </label><input type="text" name="tel" />
- <input type="submit" value="Send" data-theme="a" id="sendthis">
- </fieldset>
- </form>
- <a href="#" data-role="button" data-rel="back" data-theme="a">Cancel</a>
- </div>
I want to use a validation plugin
- $('input[name=name]').validateField({
- notEmpty : true,
- changeCase : 'title',
- message : ' Required'
- });
- $('input[name=tel]').validateField({
- notEmpty : true,
- changeCase : 'title',
- message : ' Required'
- });
-
The validation plugin works on an identical test page which is on a static page.
The form validation is bypassed when I submit the form and it closes and attempts to load my processing script when used with the dialog.
I have tried setting an ID for the submit button and simply alerting a string using document ready, but again this does not work.
I have had a look around and can't find any methods or ways of controlling behaviour of the dialog such as keeping it open.
Thanks.