Re: Error Page Question

2008-03-20 Thread Peter Stavrinides

oh no! even more work for me now... thanks anyway for your help guys!

Len Popp wrote:

You can't override the 503 error page using an 
declaration. :-(  The only way I know of to change it is to replace
org.apache.catalina.valves.ErrorReportValve with your own version,
which you specify in the "errorReportValveClass" attribute of the
 element in server.xml. I haven't tried this, but it's
documented for Tomcat 5.5 and 6.0.
  


-
To start a new topic, e-mail: users@tomcat.apache.org
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]



Re: Error Page Question

2008-03-19 Thread Len Popp
You can't override the 503 error page using an 
declaration. :-(  The only way I know of to change it is to replace
org.apache.catalina.valves.ErrorReportValve with your own version,
which you specify in the "errorReportValveClass" attribute of the
 element in server.xml. I haven't tried this, but it's
documented for Tomcat 5.5 and 6.0.
-- 
Len


On Wed, Mar 19, 2008 at 10:36 AM, Peter Stavrinides
<[EMAIL PROTECTED]> wrote:
> Unfortunately this solution doesn't solve it, I can only override 404
>  pages?, for 503 pages it simply ignores the override in web.xml, anybody
>  got any other suggestions?
>
>
>
>  Peter Stavrinides wrote:
>  > Oh thanks! that sounds quite simple... so I just add my error page
>  > descriptor in the ROOT applications web.xml and it will override.
>  >
>  > David Delbecq wrote:
>  >> The easiest way i found out here was to use the 404 of the ROOT web
>  >> application ^^ to display a 'site under maintenance'.
>  >>
>  >> You could also create a ROOT//index.html  to get same result
>  >>
>  >>
>  >>
>  >> En l'instant précis du 19/03/08 11:55, Peter Stavrinides s'exprimait en
>  >> ces termes:
>  >>> Hi all,
>  >>>
>  >>> How do I display a friendly error  page (503 site under maintenance)
>  >>> if my application is taken off-line? I understand how to override
>  >>> error pages with my application running, but can I, and where do I
>  >>> configure a 503 when its down, but Tomcat is still running.
>  >>>
>  >>> Thanks
>  >>> Peter
>  >>>
>  >>>
>  >>>
>  >>>
>  >>> -
>  >>> To start a new topic, e-mail: users@tomcat.apache.org
>  >>> To unsubscribe, e-mail: [EMAIL PROTECTED]
>  >>> For additional commands, e-mail: [EMAIL PROTECTED]
>  >>
>  >>
>  >
>  > -
>  > To start a new topic, e-mail: users@tomcat.apache.org
>  > To unsubscribe, e-mail: [EMAIL PROTECTED]
>  > For additional commands, e-mail: [EMAIL PROTECTED]
>  >
>
>  -
>  To start a new topic, e-mail: users@tomcat.apache.org
>  To unsubscribe, e-mail: [EMAIL PROTECTED]
>  For additional commands, e-mail: [EMAIL PROTECTED]
>
>


Re: Error Page Question

2008-03-19 Thread Pid

Peter Stavrinides wrote:
Unfortunately this solution doesn't solve it, I can only override 404 
pages?, for 503 pages it simply ignores the override in web.xml, anybody 
got any other suggestions?


I thought used to be possible to customise the built in error pages with 
XSL, but I can't seem to find any evidence of that in 6.x.


You *might* be able to write a Valve (configured in server.xml, under 
the Host) that acts early enough in the request / response cycle to 
return a different page, but I am in fact speculating wildly.


The org.apache.catalina.valves.ErrorReportValve uses a StringBuilder to 
create HTML and sends it to a Writer, which might make things difficult.



Valves aren't too tricky to write so it would be easy/quick to 
experiment and see if it works.


p





Peter Stavrinides wrote:
Oh thanks! that sounds quite simple... so I just add my error page 
descriptor in the ROOT applications web.xml and it will override.


David Delbecq wrote:

The easiest way i found out here was to use the 404 of the ROOT web
application ^^ to display a 'site under maintenance'.

You could also create a ROOT//index.html  to get same result



En l'instant précis du 19/03/08 11:55, Peter Stavrinides s'exprimait en
ces termes:

Hi all,

How do I display a friendly error  page (503 site under maintenance) 
if my application is taken off-line? I understand how to override 
error pages with my application running, but can I, and where do I 
configure a 503 when its down, but Tomcat is still running.


Thanks
Peter




-
To start a new topic, e-mail: users@tomcat.apache.org
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]





-
To start a new topic, e-mail: users@tomcat.apache.org
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]



-
To start a new topic, e-mail: users@tomcat.apache.org
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]





-
To start a new topic, e-mail: users@tomcat.apache.org
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]



Re: Error Page Question

2008-03-19 Thread Peter Stavrinides
Unfortunately this solution doesn't solve it, I can only override 404 
pages?, for 503 pages it simply ignores the override in web.xml, anybody 
got any other suggestions?


Peter Stavrinides wrote:
Oh thanks! that sounds quite simple... so I just add my error page 
descriptor in the ROOT applications web.xml and it will override.


David Delbecq wrote:

The easiest way i found out here was to use the 404 of the ROOT web
application ^^ to display a 'site under maintenance'.

You could also create a ROOT//index.html  to get same result



En l'instant précis du 19/03/08 11:55, Peter Stavrinides s'exprimait en
ces termes:

Hi all,

How do I display a friendly error  page (503 site under maintenance) 
if my application is taken off-line? I understand how to override 
error pages with my application running, but can I, and where do I 
configure a 503 when its down, but Tomcat is still running.


Thanks
Peter




-
To start a new topic, e-mail: users@tomcat.apache.org
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]





-
To start a new topic, e-mail: users@tomcat.apache.org
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]



-
To start a new topic, e-mail: users@tomcat.apache.org
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]



Re: Error Page Question

2008-03-19 Thread Peter Stavrinides
Oh thanks! that sounds quite simple... so I just add my error page 
descriptor in the ROOT applications web.xml and it will override.


David Delbecq wrote:

The easiest way i found out here was to use the 404 of the ROOT web
application ^^ to display a 'site under maintenance'.

You could also create a ROOT//index.html  to get same result



En l'instant précis du 19/03/08 11:55, Peter Stavrinides s'exprimait en
ces termes:

Hi all,

How do I display a friendly error  page (503 site under maintenance) 
if my application is taken off-line? I understand how to override 
error pages with my application running, but can I, and where do I 
configure a 503 when its down, but Tomcat is still running.


Thanks
Peter




-
To start a new topic, e-mail: users@tomcat.apache.org
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]





-
To start a new topic, e-mail: users@tomcat.apache.org
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]



Re: Error Page Question

2008-03-19 Thread David Delbecq

The easiest way i found out here was to use the 404 of the ROOT web
application ^^ to display a 'site under maintenance'.

You could also create a ROOT//index.html  to get same result



En l'instant précis du 19/03/08 11:55, Peter Stavrinides s'exprimait en
ces termes:

Hi all,

How do I display a friendly error  page (503 site under maintenance) 
if my application is taken off-line? I understand how to override 
error pages with my application running, but can I, and where do I 
configure a 503 when its down, but Tomcat is still running.


Thanks
Peter




-
To start a new topic, e-mail: users@tomcat.apache.org
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]



--
http://www.devlog.be (a belgian developer's logs)


-
To start a new topic, e-mail: users@tomcat.apache.org
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]