Suppose this case. I'm using Validator framework. So, I have a form with two e-mail fields and javascript validation on.
In validation.xml file I defined for the first e-mail field depends="required,email", and for the second e-mail field depends="email".
But, the result is the same. Both fields are "required".
What I want in my
JSP is validation against second e-mail field only if it was not empty. I don't want javascript message "Invalid e-mail format" on an empty e-mail field.
Is there any way to overcome this problem?