tomcat-users mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Daniel Watrous <dwmaill...@gmail.com>
Subject context path question
Date Mon, 25 Apr 2005 17:40:33 GMT
Hello,

I am have written some filters for a shopcart application.  I intend
for parts of this applicaiton to be reused in other web applications
by including it as a JAR file.

For authentication I have the file AdministratorAuthFilter, which
checks for a session value indicating that the user has logged in. 
The trouble comes with the following line:

response.sendRedirect("/simplecart/AdministratorLogin.do");

My development application is simplecart and so when I deploy to
tomcat I have a URL like "http://localhost:8080/simplecart/" which
serves as my root.  If I include this filter in another application as
part of a JAR that application will end up with another root, such as
"http://localhost:8080/mycart/".  So the line above in my filter that
includes the literal "simplecart" breaks.

I have searched for something related to the context or context path.
All suggestions appreciated.

--
DW

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


Mime
View raw message