I am trying to display, edit with validation an object which is stored in XML in the database. It's shape can change over time. I want at runtime to create a form with validation for each object stored in database.
XMl looks like this :
<root>
<name>Name</name>
</root>
View:
....
<form name="formRoot">
....
<p>Name</p><input name="name" value="Name"/>
</form>
Do you have any code examples that would help me in this matter, or if there are any libraries that do this already?
Edit 1: in c# i use this kind of xslt http://support.microsoft.com/kb/307322
Edit 2: I want to be able to add validation to each input with regex, length and type validation. Preferably using jQuery. And to do asynchronous validation as I type. For example on blur to send field name to server and get a response with valid:true if it's valid and validation message if it is not valid.