I'm using jquery validator.
I've got a custom rule applied to a group of elements in my form. These inputs may also have other (standard) rules associated with them. I need to place the error message in one place if the element fails my custom rule, but another place if the element fails a standard rule.
I need something like -
errorPlacement: function(error, element) {
if (error == MyCustomError) {
// put my error at the top of the form
} else {
// put my error next to the element
}
I can't see what that 'error' object really is (tried drilling down with firebug but it wasn't very informative).
The highlight option is even more difficult because I don't even have the 'error' parameter to use.