aspose file tools*
The moose likes Struts and the fly likes Struts client side validation Big Moose Saloon
  Search | Java FAQ | Recent Topics | Flagged Topics | Hot Topics | Zero Replies
Register / Login
JavaRanch » Java Forums » Frameworks » Struts
Bookmark "Struts client side validation" Watch "Struts client side validation" New topic
Author

Struts client side validation

saurav sarkar
Ranch Hand

Joined: Jan 07, 2007
Posts: 180

Hi All,

I have to migrate my JS code in my JSPs to Struts 1.0 validator.
I have put all the necessary code into the xml files,resource properties and the jsps.

I have many fields which are being validated in the JS functinons to be empty.If empty then an alert message.

I am trying to go one by one of these fields.I am trying for the first one where i have put the required validator in the xml files.
The code in jsp is like a js function is called which is calling the document.form.submit().

So in the html:form tag i have used the onsubmit="return validateBusinessForm(this)" so that whenever js functtion calls the submit the onsubmit method of the form should be called and the validation should happen.

But i am not able to invoke the validation.Am i doing something wrong?..

Please help


Be Objectively Oriented.Explore the power of OOPs.
My Blog, Eclipse EMF Query committer.
 
I agree. Here's the link: http://aspose.com/file-tools
 
subject: Struts client side validation