tomcat-users mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Maurice Yarrow <yar...@best.com>
Subject filter-mapping to tomcat DefaultServlet
Date Sat, 05 Nov 2005 19:58:15 GMT
Hello all

I was able to successfully use a filter to map to another servlet
in my web app.  However, I  was not able to map to tomcat's
DefaultServlet.

I tried a <filter-mapping> to <servlet-name> of "default" and
also, as the below shows, to a <servlet-name> with the fully
qualified classname for the tomcat DefaultServlet.
Neither worked.


<filter>
     <filter-name>ImageRequestFilter</filter-name>
     <filter-class>getimg.servlets.ImageRequestFilter</filter-class>
</filter>
<filter-mapping>
     <filter-name>ImageRequestFilter</filter-name>
     <url-pattern>/ImageRequest/*</url-pattern>
</filter-mapping>
<filter-mapping>
    <filter-name>ImageRequestFilter</filter-name>
    <servlet-name>default</servlet-name>
<!--
<servlet-name>org.apache.catalina.servlets.DefaultServlet</servlet-name> -->
</filter-mapping>


Is there some way to do this (without using a
RequestDispatcher.forward(...) )  ?


Maurice Yarrow


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


Mime
View raw message