tomcat-users mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From André Warnier ...@ice-sa.com>
Subject Re: the welcome file "index.jsp" returns an 302 redirection
Date Wed, 07 Jul 2010 10:25:07 GMT
lei jiang wrote:
> Hi, guys:
> 
> I am using the Tomcat 5.0.28.0, and I put the my website into webapps directory.
> 
> The welcome-file-list section likes this:
> 
> <welcome-file-list>
>     <welcome-file>index.jsp</welcome-file>
> </welcome-file-list>
> 
> In the index.jsp, I use the jsp:forward tag to forward the request to
> a struts action:
> <jsp:forward page="welcome.do"/>
> 
> When I input "http://localhost:8080/mysite" into the address bar of
> firefox and hit go button, the browser shows the correct page but the
> url in address bar changed to
> "http://localhost:8080/mysite/welcome.do"
> 
> I find that the tomcat returns a 302 redirection and then the tomcat
> returns the page generated by "welcome.do" action
> 
> So what can we do to aviod the 302 redirection and let the address bar
> just show "http://localhost:8080/mysite".
> 
Naive suggestions :

1)
  <welcome-file-list>
      <welcome-file>welcome.do</welcome-file>
  </welcome-file-list>

2) delete index.jsp and rename welcome.do to index.jsp

?


---------------------------------------------------------------------
To unsubscribe, e-mail: users-unsubscribe@tomcat.apache.org
For additional commands, e-mail: users-help@tomcat.apache.org


Mime
View raw message