Empty page instead of custom tomcat error page
Posted
by
Alexander
on Stack Overflow
See other posts from Stack Overflow
or by Alexander
Published on 2010-10-04T14:23:13Z
Indexed on
2011/01/17
13:53 UTC
Read the original article
Hit count: 319
tomcat
|custom-error-pages
My setting: Apache 2.2 + Tomcat 6.0 @ Windows 2008 R2 64bit
- static webpages: /
- servlet: /foo
- tomcat and apache are connected by mod_jk
- 404.jsp is placed in tomcat\webapps\ROOT
tomcat\conf\web.xml:
<error-page>
<error-code>404</error-code>
<location>/404.jsp</location>
</error-page>
apache\conf\extra\httpd-ssl.conf:
JkMount /foo/* worker1
JkMount /404.jsp worker1
When I open https://...../404.jsp my custom error page is displayed. But when I open https://...../foo/nonexisting.html an empty page is displayed.
If I remove the <error-page>...</error-page>
code from web.xml and open https://...../foo/nonexisting.html then tomcats own 404 is displayed.
Any hints?
© Stack Overflow or respective owner