jQuery in Action, 2nd edition
The moose likes JSP and the fly likes Where to keep “form” value Big Moose Saloon
  Search | Java FAQ | Recent Topics
Register / Login


Win a copy of The Mikado Method this week in the Agile and other Processes forum!
JavaRanch » Java Forums » Java » JSP
Reply Bookmark "Where to keep “form” value" Watch "Where to keep “form” value" New topic
Author

Where to keep “form” value

jacob deiter
Ranch Hand

Joined: Apr 02, 2008
Posts: 576
1) I design a JSP page (A)which contains drop list and text fields, each fields having values in it
2) When I navigate to next page(B) and coming back to this screen
3) All the values in its(page A) will disappears
4) To main the data in the page A, even I came back to this page(A) from Page (B),what I have to do???
Sebastian Janisch
Ranch Hand

Joined: Feb 23, 2009
Posts: 1183
Unless you use a web-framework which does this automatically for you, you need to do a bit of tedious work.

1) The parameters should be stored in the session.
2) Your A.jsp should pre-insert these values.

e.g.



JDBCSupport - An easy to use, light-weight JDBC framework -
Himanshu Kansal
Ranch Hand

Joined: Jul 05, 2009
Posts: 257
I hope by "come back" you don't mean coming back by clicking browser's back button or pressing backspace or doing HTML DOM's history.back

Regards


Experience and talent are independent of age
 
I agree. Here's the link: http://ej-technologies/jprofiler - if it wasn't for jprofiler, we would need to run our stuff on 16 servers instead of 3.
 
subject: Where to keep “form” value
 
Similar Threads
urgent help
session issue
keep the values of my input text fields
Struts2 newB: some simple questions
saving hidden fields in Action Forms