Try our conversational search powered by Generative AI!

XForms and Client-Side Validation

Hi, I was just wondering if XForms support Client-Side validation? It doesn't seem to work that way by default, as there are no elements rendered for the validation messages until after an XForm has been validated on the server-side. However, a submit button on an XForm does seem to have the Client-Side validation code in it's onclick handler. Am I just missing a setting or does this just not work by design? Cheers, Rich
Aug 08, 2007 15:41
Hi As you mentioned there is piece of code added to the submit button's onclick handler. It looks like this: if (typeof(Page_ClientValidate) == 'function') Page_ClientValidate(); It just checks if there is a function Page_ClientValidate() In my opinion everything you need is to implement your own validation. That means you just need to add Page_ClientValidate() function which is not added by default. Regards, Dariusz
Aug 10, 2007 13:41
* You are NOT allowed to include any hyperlinks in the post because your account hasn't associated to your company. User profile should be updated.