Java Mailing List Archive

http://www.junlu.com/

Home » Home (12/2007) » Apache Tomcat »

Re: Tomcat 5.5 redirect vs. forward behavior with welcome-file-list

Hassan Schroeder

2007-02-12

Replies:

On 2/12/07, Todd Gamber <tgamber@(protected):

> I realize that populating content based on what's in the URL bar is not the
> best design, but I can't seem to find another way to definitively get the
> name of the actual JSP being requested.

TSSIYF -- The Servlet Spec is your friend :-)

SRV.8.4.2 Forwarded Request Parameters
 Except for servlets obtained by using the getNamedDispatcher
method, a servlet that has been invoked by another servlet using
the forward method of RequestDispatcher has access to the path
of the original request.

The following request attributes must be set:
  javax.servlet.forward.request_uri
  javax.servlet.forward.context_path
  javax.servlet.forward.servlet_path
  javax.servlet.forward.path_info
  javax.servlet.forward.query_string

HTH!
--
Hassan Schroeder ------------------------ hassan.schroeder@(protected)

---------------------------------------------------------------------
To start a new topic, e-mail: users@(protected)
To unsubscribe, e-mail: users-unsubscribe@(protected)
For additional commands, e-mail: users-help@(protected)

©2008 junlu.com - Jax Systems, LLC, U.S.A.