aspose file tools*
The moose likes Struts and the fly likes large form spanning across multiple jsp's Big Moose Saloon
  Search | Java FAQ | Recent Topics | Flagged Topics | Hot Topics | Zero Replies
Register / Login


Win a copy of Spring in Action this week in the Spring forum!
JavaRanch » Java Forums » Frameworks » Struts
Bookmark "large form spanning across multiple jsp Watch "large form spanning across multiple jsp New topic
Author

large form spanning across multiple jsp's

manish ahuja
Ranch Hand

Joined: Oct 23, 2003
Posts: 312
All

I would like to know what is the typical practice followed for a scenario wherein there is a huge form input to fill out and the form details are spread across multiple jsp files.
The user interface is something like jsp1 , jsp2, jsp3 all holding the numerous form element data and in the jsp3 the final submit button to the server is displayed.

My question is it a good idea to have a single struts form to be used across mutliple jsp's or should be using multiple struts form objects (1 per jsp).
How is the data collected in jsp1 and jsp2 retained in the session when in jsp3 the final submit takes place.

Let me know your ideas for the same.

Thanks in Advance


David Newton
Author
Rancher

Joined: Sep 29, 2008
Posts: 12617

Usually people either (a) have a form bean containing each page's form properties and keep it in session, (b) have multiple form beans in session, or (c) use hidden form fields to hold the previous page's values. (There are other solutions as well, like keeping the form values in the DB, etc.)

I find the hidden field solution fairly brittle, but that might just be me.
 
 
subject: large form spanning across multiple jsp's