struts-user mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Affan Qureshi" <quere...@etilize.com>
Subject Re: [NEWBIE]A very stupid question
Date Mon, 17 Mar 2003 03:38:44 GMT
If you are creating a forward in struts config files or actions, you should
ignore the context name completely and write url as "/myAction.do". Struts
takes care of the context path itself.

 If you are creating links simply in HTML then do something like:
request.getContextPath() + "/myAction.do"

Look at the link Tags examples in the example apps that come with struts.

HTH.
Affan
----- Original Message -----
From: "Tony Tahbaz" <ttahbaz@attbi.com>
To: "Struts Users Mailing List" <struts-user@jakarta.apache.org>
Sent: Monday, March 17, 2003 2:16 AM
Subject: RE: [NEWBIE]A very stupid question


> How are you creating your link? Are you using the struts-html taglib or
are
> you just using html?
>
> -----Original Message-----
> From: Marco Tedone [mailto:m_tedone@hotmail.com]
> Sent: Sunday, March 16, 2003 2:07 PM
> To: Struts-user-list
> Subject: [NEWBIE]A very stupid question
>
>
> I have my application under the context /xml-op/
>
> In my struts-config.xml file, I define an action with the path=/Login
>
> Anyway, when I want to invoke the Login action as a forward, let's say by
> means of a ForwardAction action mapping, in my jsp page, as href I have to
> indicate the following: /xml-op/Login.do
>
> If I want to invoke the same action from within a form, then I have to
omit
> the /xml-op/ prefix.
>
> Anyone of you does know why?
>
> TIA, Marco
>
>
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: struts-user-unsubscribe@jakarta.apache.org
> For additional commands, e-mail: struts-user-help@jakarta.apache.org
>


---------------------------------------------------------------------
To unsubscribe, e-mail: struts-user-unsubscribe@jakarta.apache.org
For additional commands, e-mail: struts-user-help@jakarta.apache.org


Mime
View raw message