I am trying to redirect erroneous page requests - 404 errors - to a custom error page. In order for my servlet, instead of the root servlet, to handle these requests, I entered the following url-pattern:
<url-pattern>/</url-pattern>
Unfortunately, this also catches embedded requests for files like *.js, *.css, *.png, *.jpg, and other such files. Is there a way in the deployment descriptor to specify an exclusive pattern? Say, "everything EXCEPT requests with x extension"?
Or is there another way around this that I'm not seeing?