Page is a not externally linkable
- Code, Content, and Presentation
-- JavaScript and AJAX
---- Javascript Validation


Jaya - 7:04 am on Jul 22, 2002 (gmt 0)


Hi all.

I have a form with some elements. Each element can hold data of any one of the different types as text,date or integer values. I need to validate all the elements in the client side itself i.e I have to check if the element is meant for specific type of data for eg.integer. If it contains data other than integer, then alert a message to the user.

The definition for the type of the data which the element is holding is defined in an xml file.

I am using JSP and Servlet.

Can anyone tell me how I can do this? Or can anyone give me a piece of js code that is generalised for validating all elements in the form?

Thanks in advance.


Thread source:: http://www.webmasterworld.com/javascript/179.htm
Brought to you by WebmasterWorld: http://www.webmasterworld.com