Hi I have lot of fiels, so I want the user to fill up the fields in the first page and go to the next page untill all the fields are filled up and then submit, how can I have a form that submit with fields comming from previous pages ?
Please I will appreciate if you can give me an example.
One way to do that would be to put in hidden fields in the second page:
<input type="hidden" name="test" value="<%=request.getParameter("test")%>">
Usha's approach is OK if there are very few fields to be handled. This gets too complicated, and not a good design if you have lot of fields in your pages.
I understand, u r trying to create a wizard sort of thing.
One simple way is to create a Value Object of what you are trying to create and keep it in the user session. When the user traverses through the wizard (several other pages), keep updating the Value object thats present in the user session. Once it reaches the last page of the wizard, use the value object thats there in the user session to create or update or whatever you want to do with it. Then remove this value object from the user session ... ...
Did u get what I'm saying?
yes, it's a good idea, any example will be helpful.