tomcat-users mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "nfet nfet" <nf...@msn.com>
Subject Re: Different behavior when forwarding to *.jsp and *.html in WEB-INF
Date Thu, 08 Nov 2001 15:38:16 GMT
Hi Jan,

I am not sure if this is due to the fact that you are not suppose to be able to access the
WEB-INF directory by default, since we are not aware of what you are running, i.e. Apache
with Tomcat or straight Tomcat.

Try taking the jsp and html outside of the directory and place it on the ROOT path then RUN
the test AGAIN.

I hope this helps.

nfet  
  
----- Original Message -----
From: Jan.Hansen@carat.dk
Sent: Wednesday, November 07, 2001 10:56 AM
To: tomcat-user@jakarta.apache.org
Subject: Different behavior when forwarding to *.jsp and *.html in WEB-INF
  
In the attached webapp, outlined in diagram below i see some rather
strange behavior (result of my feeble attempt to isolate the problem).

http://localhost:8080/example/redirectOK.jsp returns ok.jsp

http://localhost:8080/example/redirectBAD.jsp returns empty document

I would have expected both requests to behave in a similar manner
is this a bug or is there a reason why outcome differs ?

/ -+- redirectOK.jsp
   |    <%pageContext.forward("WEB-INF/jsp/ok.jsp");%>
   |
   +- redirectBAD.jsp
   |    <%pageContext.forward("WEB-INF/jsp/bad.html");%>
   |
   +- WEB-INF -+- web.xml
               | <web-app>
               | </web-app>
               |
               +- jsp -+- ok.jsp
                       | <HTML>
                       |  <BODY>
                       |   <H1>ok.jsp</H1>
                       |  </BODY>
                       | </HTML>
                       |
                       +- bad.html
                         <HTML>
                          <BODY>
                           <H1>bad.html</H1>
                          </BODY>
                         </HTML> --
To unsubscribe:   <mailto:tomcat-user-unsubscribe@jakarta.apache.org>
For additional commands: <mailto:tomcat-user-help@jakarta.apache.org>
Troubles with the list: <mailto:tomcat-user-owner@jakarta.apache.org> Get more from
the Web.  FREE MSN Explorer download : http://explorer.msn.com

Mime
  • Unnamed multipart/alternative (inline, None, 0 bytes)
View raw message