Search code examples
jqueryjquery-uijquery-validatejquery-tabs

Jquery validate function


I have a form that is broken down into three different categories: Information, Violations, and Important dates. I need to perform form validation in the information, and Important dates categories(which are the 1st and 3rd tabs, respectively). How can I keep track of which inputs are valid and which aren't so that I can send the user to the right tab to fix errors? I am using Jquery validate plug-in from Jorn Zaefferer. Any help in the right direction would be greatly appreciated.

Thanks


Solution

  • you can find elements which have errors with jquery, they will be marked by an attribute or class(I can't remember exactly), then you can use the parentUntil function to find the tab and select it.