• Status: Solved
  • Priority: Medium
  • Security: Public
  • Views: 1767
  • Last Modified:

Tomcat error page


I want a custom error page to handle all types of tomcat errors. Is it possible without having to add the errorPage directive to every single JSP?

1 Solution
Maybe you can use a redirect to a error page
well if you are using some form of MVC pattern I am sure there are many points where yuo can intersect the error and redirect to the desired JSP.

For example in struts you have a directive in the struts-config file that will let you do that.

Also web.xml has the error-page element with the following nested elem

 A valid HTTP error code, for example, 404.
 A fully-qualified class name of a Java exception type, for example, java.lang.string
 The location of the resource to display in response to the error. For example, /myErrorPg.html.

Naveen Sydney

Question has a verified solution.

Are you are experiencing a similar issue? Get a personalized answer when you ask a related question.

Have a better answer? Share it in a comment.

Join & Write a Comment

Featured Post

Free Tool: Site Down Detector

Helpful to verify reports of your own downtime, or to double check a downed website you are trying to access.

One of a set of tools we are providing to everyone as a way of saying thank you for being a part of the community.

Tackle projects and never again get stuck behind a technical roadblock.
Join Now