You are viewing a plain text version of this content. The canonical link for it is here.
Posted to users@tomcat.apache.org by Koon Yue Lam <ki...@gmail.com> on 2004/07/10 22:45:49 UTC
About
Hi, I place member.jsp in my webapp root folder, which is
<TOMCAT_HOME> --> webapp -->myWebApp/
and part of web.xml :
<servlet-mapping>
<servlet-name>action</servlet-name>
<url-pattern>*.do</url-pattern>
</servlet-mapping>
part of struts-config.xml:
<action-mappings >
<action
path="/Index"
type="com.kiss.web.news.actions.Index"
unknown="false"
validate="true">
<forward
name="member"
path="/Member.jsp"
redirect="false"
contextRelative="false" />
</action>
</action-mappings>
I call http://localhost:8080/Index.do and member.jsp is shown
but when I change the
<url-pattern>*.do</url-pattern>
to
<url-pattern>/*</url-pattern>
then I call http://localhost:8080/Index
Index has been called with this error msg:
"Invalid path /Member.jsp was requested"
How can I fix it? I don't want to type some .do or .action sort of
thing in my url, I type want the url like :
http://localhost:8080/Index
with no extension
Any help?
Regards
---------------------------------------------------------------------
To unsubscribe, e-mail: tomcat-user-unsubscribe@jakarta.apache.org
For additional commands, e-mail: tomcat-user-help@jakarta.apache.org
Re: About
Posted by Koon Yue Lam <ki...@gmail.com>.
Hi Jarl !
sorry, I still don't get what u mean....
I try to place
<welcome-file-list>
<welcome-file>/Member.jsp</welcome-file>
</welcome-file-list>
in web.xml and keep the mapping as :
<servlet-mapping>
<servlet-name>action</servlet-name>
<url-pattern>/*</url-pattern>
</servlet-mapping>
but I still got the
"Invalid path /Member.jsp was requested"
error message...
can u please help me a little deeper?
I want to use the URL like:
http://localhost:8080/Index
rather than:
http://localhost:8080/Index.do
any help will be appreciated
Regards
---------------------------------------------------------------------
To unsubscribe, e-mail: tomcat-user-unsubscribe@jakarta.apache.org
For additional commands, e-mail: tomcat-user-help@jakarta.apache.org
Re: About
Posted by Jarl Skogsholm <ja...@lamarido.net>.
keep the original mapping, but also add it to your welcome file list
On Sun, 11 Jul 2004 04:45:49 +0800, Koon Yue Lam <ki...@gmail.com>
wrote:
> Hi, I place member.jsp in my webapp root folder, which is
> <TOMCAT_HOME> --> webapp -->myWebApp/
>
> and part of web.xml :
> <servlet-mapping>
> <servlet-name>action</servlet-name>
> <url-pattern>*.do</url-pattern>
> </servlet-mapping>
>
> part of struts-config.xml:
> <action-mappings >
> <action
> path="/Index"
> type="com.kiss.web.news.actions.Index"
> unknown="false"
> validate="true">
> <forward
> name="member"
> path="/Member.jsp"
> redirect="false"
> contextRelative="false" />
> </action>
> </action-mappings>
>
> I call http://localhost:8080/Index.do and member.jsp is shown
> but when I change the
> <url-pattern>*.do</url-pattern>
> to
> <url-pattern>/*</url-pattern>
>
> then I call http://localhost:8080/Index
>
> Index has been called with this error msg:
> "Invalid path /Member.jsp was requested"
>
> How can I fix it? I don't want to type some .do or .action sort of
> thing in my url, I type want the url like :
> http://localhost:8080/Index
>
> with no extension
>
> Any help?
>
> Regards
>
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: tomcat-user-unsubscribe@jakarta.apache.org
> For additional commands, e-mail: tomcat-user-help@jakarta.apache.org
--
They that can give up essential liberty to obtain a little temporary
safety deserve neither liberty nor safety.
-- Benjamin Franklin (1755)
---------------------------------------------------------------------
To unsubscribe, e-mail: tomcat-user-unsubscribe@jakarta.apache.org
For additional commands, e-mail: tomcat-user-help@jakarta.apache.org