Help coderanch get a
new server
by contributing to the fundraiser
  • Post Reply Bookmark Topic Watch Topic
  • New Topic
programming forums Java Mobile Certification Databases Caching Books Engineering Micro Controllers OS Languages Paradigms IDEs Build Tools Frameworks Application Servers Open Source This Site Careers Other Pie Elite all forums
this forum made possible by our volunteer staff, including ...
Marshals:
  • Campbell Ritchie
  • Ron McLeod
  • Paul Clapham
  • Devaka Cooray
  • Liutauras Vilda
Sheriffs:
  • Jeanne Boyarsky
  • paul wheaton
  • Henry Wong
Saloon Keepers:
  • Stephan van Hulst
  • Tim Holloway
  • Tim Moores
  • Carey Brown
  • Mikalai Zaikin
Bartenders:
  • Lou Hamers
  • Piet Souris
  • Frits Walraven

Maintaining form data across pages...

 
Ranch Hand
Posts: 80
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
Dears,

I am trying to setup a series of jsp pages (requestForm, confrimation jsp).

I set the scope of my requestForm to "session" as to maintain the data across the various jsps, but I get it as if reset is called, after the confirmation page submits

What is the best way to maintain the request data across several jsp pages, speically I have lots of pages as step 1, step 2, step 3 before submiting the action, with different form beans.


Thanks, best regards
 
Ranch Hand
Posts: 415
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
Hi

Its a part of the framework that whenever u fire a request the reset method will be executed and then remaining things.........the default implemenattion of reset deosnt have anything

so if u wnat to maintain ur formdata across many pages ........keep that formbean in session scope and dont override that reset method .ie dont provode any implementation.........

i hope this will solve ur problem
 
Ranch Hand
Posts: 1312
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
u can use javabean + web session scope together
 
Ranch Hand
Posts: 62
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
You can associate the same for bean to the different action classes or you can extend the form beans of the other action classes with the form bean which you need in the others and make the scope of this form bean as session
 
Consider Paul's rocket mass heater.
reply
    Bookmark Topic Watch Topic
  • New Topic