I am currently working on a Struts application. For form variable validation we use javascript instead of validator. Is there any problem using validator?
Hi there is no problem in using validator. Most of the general validations we need to performs for the fields in the form, have been covered by validation.You just need to associate your fields with the required validations in your application level validation.xml file.
One problem I am facing now is the client-side validation will import all validate scripts even if you don't need them. It will make your HTML page very big.
This method is still unacceptably awkward for me, since I have no idea how many rows there will be in a dynamic table at run time. If I have 500 rows, am I going to repeat this code 500 times?
As I see it, the only acceptable solution for client-side validation of indexed properties is to write my own javascript code.