|
I have a web application that has 2 filters and a welcome file configured in the web.xml. The filters work when the url running the app explicitly contains a page, i.e. http://xxx/webapp/page.jsp. If the url doesn't contain a page, i.e. http://xxx/webapp/ the filters are ignored, but the welcome page is found correctly. What am I doing wrong? Here is my web.xml <filter> <filter-name>Filter1</filter-name> <filter-class>Filter1</filter-class> </filter> <filter-mapping> <filter-name>Filter1</filter-name> <url-pattern>/*</url-pattern> </filter-mapping> <filter> <filter-name>Filter2</filter-name> <filter-class>Filter2</filter-class> </filter> <filter-mapping> <filter-name>Filter2</filter-name> <url-pattern>/*</url-pattern> </filter-mapping> <welcome-file-list> <welcome-file>page.jsp</welcome-file> </welcome-file-list>
As an Amazon Associate we earn from qualifying purchases.
This mailing list archive is Copyright 1997-2024 by midrange.com and David Gibbs as a compilation work. Use of the archive is restricted to research of a business or technical nature. Any other uses are prohibited. Full details are available on our policy page. If you have questions about this, please contact [javascript protected email address].
Operating expenses for this site are earned using the Amazon Associate program and Google Adsense.