Hi, In my application, controls are generated dynamically. I want to know if I can configure rules by giving CSS classes and NOT by specifiying element name while validating the fields.
I tried following code and works in some scenarios: var isValid = $("#questionAnswerForm").validate({ errorLabelContainer: "#messageBox", wrapper: "li" }); if(isValid != null && !isValid.form()){ return false; } I am using struts controls like <html:radio>, <html:text> etc. If I specify error message in "title" and class="required" then works for radio, text,textarea. But how can I configure rules in this situation for e-mail, date, number, checkbox, fileupload control, matrix control fields? Can I specify CSS class in rules under validate() ?