You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@httpd.apache.org by Geoffrey Young <ge...@modperlcookbook.org> on 2004/04/06 02:36:51 UTC

restore ErrorDocument to default serer message

hi all

today in bugzilla Joshua brought up an interesting point about ErrorDocument
- once set on a global or per-server level you can't selectively restore the
error response back to the canned server document.

  http://issues.apache.org/bugzilla/show_bug.cgi?id=28173

while the current userland solution is well known and standard practice, the
logic to reset the ErrorDocument is back to the default is trivial:

  conf->response_code_strings[idx] = NULL;

over in mod_perl land we support this through the custom_response() API, but
it would be kind of cool to be able to support

  ErrorDocument 500 default

in core httpd, allowing users to effectively restore the canned server
response for the scope of the current ErrorDocument.

anyway, I'm just tossing the idea out there - if people like it I'll work up
a patch.  if not, no biggie.

--Geoff

Re: restore ErrorDocument to default serer message

Posted by Geoffrey Young <ge...@modperlcookbook.org>.

Cliff Woolley wrote:
> On Mon, 5 Apr 2004, Geoffrey Young wrote:
> 
> 
>>  ErrorDocument 500 default
>>
>>in core httpd, allowing users to effectively restore the canned server
>>response for the scope of the current ErrorDocument.
>>
>>anyway, I'm just tossing the idea out there - if people like it I'll work up
>>a patch.  if not, no biggie.
> 
> 
> Seems reasonable to me; +1 on concept.

cool.

patch and self-contained test attached.

--Geoff

Re: restore ErrorDocument to default serer message

Posted by Cliff Woolley <jw...@virginia.edu>.
On Mon, 5 Apr 2004, Geoffrey Young wrote:

>   ErrorDocument 500 default
>
> in core httpd, allowing users to effectively restore the canned server
> response for the scope of the current ErrorDocument.
>
> anyway, I'm just tossing the idea out there - if people like it I'll work up
> a patch.  if not, no biggie.

Seems reasonable to me; +1 on concept.