If you're validation script is running on form's "onSubmit" event. I suspect
these scripts won't get fired with AjaxSubmitButton however you can fire them
in onClickBefore event of AjaxSubmitButton and if the script returns true the
data will be posted to the action E.g.
Case 1: Normal Submit Button
<wo:form onSubmit="someValidations()">
<input type="text" name="field1"/>
<wo:submit action="$postData" value="Post Data"/>
</wo:form>
Case 2: AjaxSubmitButton
<wo:form>
<input type="text" name="field1"/>
<wo:AjaxSubmitButton action="$postData" value="Post Data"
onClickBefore="someValidation()"/>
</wo:form>
I hope case 2 would work for you or at least would give some hints. But it's
better if you could post some code so problem could be understood properly.
http://webobjects.insigno.net/wonder/api/er/ajax/AjaxSubmitButton.html
Farrukh
On 2010-04-22, at 8:39 PM, Kalpana Vaka wrote:
> Hi All,
>
> I have javascript file validation.js with all the client side validations for
> text, numbers, dates etc.,.
>
> When I use WOJavascript with normal submit button, the validations are being
> raised.
>
> But, when I use AjaxSubmitButton instead of normal submit button, the
> validations from the js file are being called.
>
> Can anyone help me with this?
>
> Thanks in advance,
> Kalpana.
> _______________________________________________
> Do not post admin requests to the list. They will be ignored.
> Webobjects-dev mailing list ([email protected])
> Help/Unsubscribe/Update your Subscription:
> http://lists.apple.com/mailman/options/webobjects-dev/farrukh.ijaz%40fuegodigitalmedia.com
>
> This email sent to [email protected]
_______________________________________________
Do not post admin requests to the list. They will be ignored.
Webobjects-dev mailing list ([email protected])
Help/Unsubscribe/Update your Subscription:
http://lists.apple.com/mailman/options/webobjects-dev/archive%40mail-archive.com
This email sent to [email protected]