For every calling page, use a new mapping in yr struts-config.

I assume u mean setting the action as session scope in yr config? They
are the same I think, the important thing is to keep it to one solution
and use it thoughout the application. Else it will be confusing and hard
to debug as yr application grows.

Sebastian


On Wed, 2004-10-13 at 08:59, lixin chu wrote:
> Hi,
> I am seeking your expert advice:
> I have a simple page with Done and Cancel buttons. If
> any of these buttons are clicked, I suppose to go back
> to the calling page - there are a few pages that will
> come to this page. It is a simple workflow type of
> thing. 
> So I need to know the retutn URL, pls some other
> stuff.
> 
> The question is, where do I keep the return URL which
> is passed in as request attribute ? 
> 
> Since the current page has some other buttons not just
> Done and Cancel, I use LookupDispatchAction, that
> means I have to keep the return URL in the session.
> Which one is a better solution: keeping it in the
> session scoped ActionForm or
> request.getSession().setAttribute ? 
> 
> It is easier to manage the return URL if put into
> ActionForm becuase it is isolated, no naming
> conflict-bur ActionForm is for UI components only;
> otherwise, I need to keep it in the session using a
> name reference something like myAction_returnURL, and
> also I need to handle the cleaning - it is still
> possible that the sting is kept in the session until
> the session is closed if the user does not click Done
> or Cancel.
> 
> any best practice ? may be the best is to avoid using
> session scope objects but I just can not think of a
> way out for my use case.
> 
> thanks in advance
> LX
> 
> 
> 
> 
> __________________________________________________
> Do You Yahoo!?
> Tired of spam?  Yahoo! Mail has the best spam protection around 
> http://mail.yahoo.com
> 
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: [EMAIL PROTECTED]
> For additional commands, e-mail: [EMAIL PROTECTED]
> 
> 


---------------------------------------------------------------------
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]

Reply via email to