Win a copy of Re-engineering Legacy Software this week in the Refactoring forum
or Docker in Action in the Cloud/Virtualization forum!
  • Post Reply
  • Bookmark Topic Watch Topic
  • New Topic

the old form values

 
prat narang
Greenhorn
Posts: 10
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
hi group,
i have one jsp page with some input fields and a submit button.
i've different links to reach this page. and my requirement is that if i am reaching at this page first time then the field should be blank otherwise it should show the values which i've entered previously.
could anybody tell me the way to proceed....
thank you
--prateek--
 
Winston Smith
Ranch Hand
Posts: 136
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
You'll need to implement some sort of session tracking, to keep track of first-time visitors to the page, and repeat visitors. An easy way to do this is to use set a session variable (e.g. session.setAttribute()). If you're wanting your form values to persist throughout pages, you can use a JavaBean to store the values as the user navigates through the pages.
 
prat narang
Greenhorn
Posts: 10
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
thank you Winston Smith, I've done the things in the same way as u said. and it's working fine.
thank you
--prateek--
 
  • Post Reply
  • Bookmark Topic Watch Topic
  • New Topic