tomcat-users mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Eric B." <>
Subject Re: Custom 404 for non-existant contexts?
Date Wed, 06 Feb 2008 23:03:02 GMT
"Caldarale, Charles R" <> wrote in message
>> Subject: Custom 404 for non-existant contexts?
>> Is there a way to create a custom 404 error page for Tomcat
>> for non-existant context paths?

>What happens if you declare a custom error page for the ROOT (default)

Yeah - that's pretty much the only thing I managed to figure out.  I updated 
the conf/web.xml file to include

and put the /error/maintenance.html in the ROOT directory.

Of course, the ugly part about this is that a) /error/maintenance.html is 
now accessible through my root app (unless otherwise protected), and I need 
to have a separate ROOT/error/maintenance.html for each individual Tomcat 
instance.  I was hoping to be able to centralize the error msgs (as in 
httpd), but didn't have any success.  I tried using a symlink to point my 
error/ folder to a central location, but Tomcat didn't follow the link.

Not the prettiest soln, but functional.  Would be nice if I could make it 
nicer tho.



To start a new topic, e-mail:
To unsubscribe, e-mail:
For additional commands, e-mail:

View raw message