Prashant Khanal wrote:
Hello all,
I have two jsp pages say Page1 and Page2 backed by their corresponding
action. When the Page1 is first loaded the corresponding action's prepare()
method is used to provide the data for the page based on the parameter sent
by the page that precedes the Page1. Upon submit the user is navigated to
Page2 and upon submit on that page(Page2) the user is navigated back to
Page1. Now the parameter used to provide the data for Page1 is lost as it
was provided by another page. So Is there any way that i can persist the
action properties during this process.
Is session only efficient way to do that or is there any alternative?
I have been using session to store the properties for now.
You have at least a couple of choices:
1) use the session
2) propagate the parameter sent to Page1 by placing it as a hidden field
in Page2
The second option may require additional work to pass the parameter from
Page1 to Page2 back to Page1 again, but may simplify Page1's logic for
using the data, since it can always find it in the same place (the
request parameters) rather than having to check two places (the request
parameters and the session).
L.
---------------------------------------------------------------------
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]