Randy already gave you an answer.

In the interceptor that checks for a logged-in user (or an action subclass,
but an interceptor is probably better) save the URL that was being requested.
After login check for the presence of this URL and if there redirect to it.

It's unlikely you'll get many answers that will be significantly different
from that basic concept, although the specifics may vary somewhat.

Dave

--- Dravid <[EMAIL PROTECTED]> wrote:

> 
> please some one help me
> 
> thanks in advance
> 
> 
> 
> Dravid wrote:
> > 
> > Hi,
> > 
> > After a successful login I don't want to redirect the user to a hardcodes
> > page, but I want the user to be redirected where he wanted to go. E.g. if
> > a user clicks on 'sell' he will be forced to log in and after login the
> > sell-page should be shown. If he clicks on buy the buy-page should be
> > shown after login. Is there an elegant way to do this?"
> > 
> > please help with a piece of code.
> > 
> > thanks in advance
> > 
> 
> -- 
> View this message in context:
>
http://www.nabble.com/How-to-redirect-to-the-same-page-tp15436570p15459605.html
> Sent from the Struts - User mailing list archive at Nabble.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