You are viewing a plain text version of this content. The canonical link for it is here.
Posted to user@struts.apache.org by Jesse Vitrone <jv...@giantbear.com> on 2001/04/16 15:44:59 UTC

encoded URLs

If I do a mapping.getForward("x"), is the URL that goes to encoded with
the session and stuff?

Thanks,
	Jesse

Re: encoded URLs

Posted by "Craig R. McClanahan" <cr...@apache.org>.

On Mon, 16 Apr 2001, Jesse Vitrone wrote:

> If I do a mapping.getForward("x"), is the URL that goes to encoded with
> the session and stuff?
> 

It depends on how and where you are using it.

If you are just returning an ActionForward from your
Action.perform() method to the controller servlet, there is no need for
encoding at that point -- Struts will do a RequestDispatcher.forward() to
the JSP page in the context of the same request, so there is no need for
any encoding.

On the other hand, if you juse the forward value to create a hyperlink:

  <html:link forward="x">Click Me!</html:link>

then the appropriate URL rewriting to maintain session state will occur
automatically (as long as you use the Struts tags to create the links :-).


> Thanks,
> 	Jesse
> 

Craig