Re: http errors
I tried what you said, put the error-page in the web.xml in the WEB-INF inside my app(webapps/test/WEB-INF) and in the web.xml in the conf directory( tomcat/conf). I´m using tomcat 3.2.1 and win2000, i tried in tomcat 3.3 and it didn´t workout either, what could be wrong? - Original Message - From: Hughes, Tim To: '[EMAIL PROTECTED]' Sent: Wednesday, July 04, 2001 4:39 AM Subject: RE: http errors Hi, You will find a full copy of the **default** web.xml in TOMCAT_HOME/conf/. What is the default web.xml -- Extract from the user guide (which you will find at TOMCAT_HOME\doc\uguide\tomcat_ug.html: recommended reading) [A detailed description of web.xml and the web application structure (including directory structure and configuration) is available in chapters 9, 10 and 14 of the Servlet API Spec and we are not going to write about it. There is however a small Tomcat related "feature" that is related to web.xml. Tomcat lets the user define defaultw eb.xml values for all context by putting a default web.xml file in the conf directory. When constructing a new Context, Tomcat uses the default web.xml file as the base configuration and the application specific web.xml (the one located in the application's WEB-INF/web.xml), only overwrite these defaults.] So if you want the error pages to apply to all webapps then you put the error page tags in the default web.xml like this: ?xml version="1.0" encoding="ISO-8859-1"? !DOCTYPE web-app PUBLIC "-//Sun Microsystems, Inc.//DTD Web Application 2.2//EN" "http://java.sun.com/j2ee/dtds/web-app_2_2.dtd" web-app !--IMPORTANT: all the tags that were already in the default web.xmlfile should remain in the file-- error-page exception-typejavax.servlet.TryagainException/exception-type location/errors/TryAgain.html/location /error-page error-page error-code503/error-code location/errors/TryAgain.html/location /error-page /web-app (I assume that you have renamed the directories and files accordingly: errors directory and TryAgain.html file are only examples). If you only want the error pages to apply to a particular webapp then you should create a web.xml file that you place in TOMCAT_HOME/webapps/yourWebApp/WEB-INF. This file should look like this: !DOCTYPE web-app PUBLIC "-//Sun Microsystems, Inc.//DTD Web Application 2.2//EN" "http://java.sun.com/j2ee/dtds/web-app_2_2.dtd" web-app error-page exception-typejavax.servlet.TryagainException/exception-type location/errors/TryAgain.html/location /error-page error-page error-code503/error-code location/errors/TryAgain.html/location /error-page /web-app I hope this works. Tim Hughes -Original Message-From: Francisco Areas Guimaraes [mailto:[EMAIL PROTECTED]]Sent: 4. juli 2001 02:25To: [EMAIL PROTECTED]Subject: Re: http errors it didn´t work...could you please give a "complete" web.xml? and where should I put this file? in %TOMCAT_HOME%/conf or somewhere else? I´m using tomcat 3.2.2 and win2k, I would like any help you could provide, because I just started working with tomcat. thanks, Francisco [EMAIL PROTECTED] - Original Message - From: Hughes, Tim To: '[EMAIL PROTECTED]' Sent: Tuesday, July 03, 2001 4:29 AM Subject: RE: http errors Hi, Using error-page elements in the web.xml, you can program web applications to handle HTTP errors and exceptions. The deployment description below makes the container send the /errors/TryAgain.html file if either a TryAgainExeption or the HttpServletResponse.SC_SERVER_UNAVAILABLE error code occurs: web-app !-- Servlet definitions -- error-page exception-typejavax.servlet.TryagainException/exception-type location/errors/TryAgain.html/location /error-page error-page error-code503/error-code location/errors/TryAgain.html/location /error-page I hope this helps. Tim Hughes -Original Message-From: Francisco Areas Guimaraes [mailto:[EMAIL PROTECTED]]Sent: 3. juli 2001 02:15To: Lista tomcat UserSubject: http errors Anyone know if I can set tomcat to use a custom page for http errors, like 500, instead of it´s default???
RE: http errors
Hi, You will find a full copy of the **default** web.xml in TOMCAT_HOME/conf/. What is the default web.xml -- Extract from the user guide (which you will find at TOMCAT_HOME\doc\uguide\tomcat_ug.html: recommended reading) [A detailed description of web.xml and the web application structure (including directory structure and configuration) is available in chapters 9, 10 and 14 of the Servlet API Spec and we are not going to write about it. There is however a small Tomcat related "feature" that is related to web.xml. Tomcat lets the user define defaultw eb.xml values for all context by putting a default web.xml file in the conf directory. When constructing a new Context, Tomcat uses the default web.xml file as the base configuration and the application specific web.xml (the one located in the application's WEB-INF/web.xml), only overwrite these defaults.] So if you want the error pages to apply to all webapps then you put the error page tags in the default web.xml like this: ?xml version="1.0" encoding="ISO-8859-1"? !DOCTYPE web-app PUBLIC "-//Sun Microsystems, Inc.//DTD Web Application 2.2//EN" "http://java.sun.com/j2ee/dtds/web-app_2_2.dtd" web-app !--IMPORTANT: all the tags that were already in the default web.xmlfile should remain in the file-- error-page exception-typejavax.servlet.TryagainException/exception-type location/errors/TryAgain.html/location /error-page error-page error-code503/error-code location/errors/TryAgain.html/location /error-page /web-app (I assume that you have renamed the directories and files accordingly: errors directory and TryAgain.html file are only examples). If you only want the error pages to apply to a particular webapp then you should create a web.xml file that you place in TOMCAT_HOME/webapps/yourWebApp/WEB-INF. This file should look like this: !DOCTYPE web-app PUBLIC "-//Sun Microsystems, Inc.//DTD Web Application 2.2//EN" "http://java.sun.com/j2ee/dtds/web-app_2_2.dtd" web-app error-page exception-typejavax.servlet.TryagainException/exception-type location/errors/TryAgain.html/location /error-page error-page error-code503/error-code location/errors/TryAgain.html/location /error-page /web-app I hope this works. Tim Hughes -Original Message-From: Francisco Areas Guimaraes [mailto:[EMAIL PROTECTED]]Sent: 4. juli 2001 02:25To: [EMAIL PROTECTED]Subject: Re: http errors it didn´t work...could you please give a "complete" web.xml? and where should I put this file? in %TOMCAT_HOME%/conf or somewhere else? I´m using tomcat 3.2.2 and win2k, I would like any help you could provide, because I just started working with tomcat. thanks, Francisco [EMAIL PROTECTED] - Original Message - From: Hughes, Tim To: '[EMAIL PROTECTED]' Sent: Tuesday, July 03, 2001 4:29 AM Subject: RE: http errors Hi, Using error-page elements in the web.xml, you can program web applications to handle HTTP errors and exceptions. The deployment description below makes the container send the /errors/TryAgain.html file if either a TryAgainExeption or the HttpServletResponse.SC_SERVER_UNAVAILABLE error code occurs: web-app !-- Servlet definitions -- error-page exception-typejavax.servlet.TryagainException/exception-type location/errors/TryAgain.html/location /error-page error-page error-code503/error-code location/errors/TryAgain.html/location /error-page I hope this helps. Tim Hughes -Original Message-From: Francisco Areas Guimaraes [mailto:[EMAIL PROTECTED]]Sent: 3. juli 2001 02:15To: Lista tomcat UserSubject: http errors Anyone know if I can set tomcat to use a custom page for http errors, like 500, instead of it´s default??? please, help me, i´ve tried a lot of things and it didn´t help. []´s FranciscoThis message contains information that may be privileged or confidential and is the property of the Cap Gemini Ernst Young Group. It is intended only for the person to whom it is addressed. If you are not the intended recipient, you are not authorized to read, print, retain, copy, disseminate, distribute, or use this message or any part thereof. If you receive this message in error, please notify the sender immediately and delete all copies of this message. This message contains information that may be privileged or confidential and is the property of the Cap Gemini Ernst & Young Group. It is intended onl
RE: http errors
Hi, Using error-page elements in the web.xml, you can program web applications to handle HTTP errors and exceptions. The deployment description below makes the container send the /errors/TryAgain.html file if either a TryAgainExeption or the HttpServletResponse.SC_SERVER_UNAVAILABLE error code occurs: web-app !-- Servlet definitions -- error-page exception-typejavax.servlet.TryagainException/exception-type location/errors/TryAgain.html/location /error-page error-page error-code503/error-code location/errors/TryAgain.html/location /error-page I hope this helps. Tim Hughes -Original Message-From: Francisco Areas Guimaraes [mailto:[EMAIL PROTECTED]]Sent: 3. juli 2001 02:15To: Lista tomcat UserSubject: http errors Anyone know if I can set tomcat to use a custom page for http errors, like 500, instead of it´s default??? please, help me, i´ve tried a lot of things and it didn´t help. []´s Francisco This message contains information that may be privileged or confidential and is the property of the Cap Gemini Ernst & Young Group. It is intended only for the person to whom it is addressed. If you are not the intended recipient, you are not authorized to read, print, retain, copy, disseminate, distribute, or use this message or any part thereof. If you receive this message in error, please notify the sender immediately and delete all copies of this message.
Re: http errors
it didn´t work...could you please give a "complete" web.xml? and where should I put this file? in %TOMCAT_HOME%/conf or somewhere else? I´m using tomcat 3.2.2 and win2k, I would like any help you could provide, because I just started working with tomcat. thanks, Francisco [EMAIL PROTECTED] - Original Message - From: Hughes, Tim To: '[EMAIL PROTECTED]' Sent: Tuesday, July 03, 2001 4:29 AM Subject: RE: http errors Hi, Using error-page elements in the web.xml, you can program web applications to handle HTTP errors and exceptions. The deployment description below makes the container send the /errors/TryAgain.html file if either a TryAgainExeption or the HttpServletResponse.SC_SERVER_UNAVAILABLE error code occurs: web-app !-- Servlet definitions -- error-page exception-typejavax.servlet.TryagainException/exception-type location/errors/TryAgain.html/location /error-page error-page error-code503/error-code location/errors/TryAgain.html/location /error-page I hope this helps. Tim Hughes -Original Message-From: Francisco Areas Guimaraes [mailto:[EMAIL PROTECTED]]Sent: 3. juli 2001 02:15To: Lista tomcat UserSubject: http errors Anyone know if I can set tomcat to use a custom page for http errors, like 500, instead of it´s default??? please, help me, i´ve tried a lot of things and it didn´t help. []´s FranciscoThis message contains information that may be privileged or confidential and is the property of the Cap Gemini Ernst Young Group. It is intended only for the person to whom it is addressed. If you are not the intended recipient, you are not authorized to read, print, retain, copy, disseminate, distribute, or use this message or any part thereof. If you receive this message in error, please notify the sender immediately and delete all copies of this message.
Re: http errors
hi Francisco, Use error-document in web.xml. Its covered in the Servlet 2.2 spec. cheers dim On Tue, 3 Jul 2001 10:14, you wrote: Anyone know if I can set tomcat to use a custom page for http errors, like 500, instead of it´s default??? please, help me, i´ve tried a lot of things and it didn´t help. []´s Francisco Content-Type: text/html; charset=iso-8859-1; name=Attachment: 1 Content-Transfer-Encoding: quoted-printable Content-Description: