it all depends... Do you want to do the validation client side or
server side? If you do it client side, in JS you can return false
in the onsubmit event of the form which will prevent the form from
actually being submitted. If it has to be done on the server side,
then you should investigate using a hash table to store field name/
value pairs. JSON is a data definition language that should be of
interest to you here... You could bundle all the form data into a
single object and pass that back to the form and repopulate all of
the fields quickly in the onload of the window.
some useful links..
Information about JSON
http://www.json.org/
Information about Prototype. This should make dealing with your forms
a bit easier... think of the power you have with the ability to hit the
server and process the response without refreshing the whole page.
http://prototype.conio.net/ http://www.sergiopereira.com/articles/prototype.js.html
This library builds on prototype.js by letting you use CSS Selectors to
assign methods to your elements.
http://bennolan.com/behaviour/
D.