httpd-modules-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From John Zhang <john_zzh...@yahoo.com>
Subject Re: How does set status code in filter work
Date Mon, 10 Dec 2007 19:59:27 GMT
Joe,
    Thanks for you rreply, but I do not quite
understand "Your filter should run before the content
type is set".  Could you elaberated on that? My filter
is an output filter.

    Also, if I issue a redirect in my (output) filter
to (say /errors/HTTP_FORBIDDEN.html) and I am a filter
for .html, will I be called in loading the error page?

Thanks,
John

--- Joe Lewis <joe@joe-lewis.com> wrote:

> Your filter should run before the content type is
> set.  Then, you can do 
> the usual redirect to /errors/HTTP_FORBIDDEN.html or
> whatever document 
> you should be returning.  Yes, a filter should only
> be working on the 
> through-put, so you should be handling that. 
> Perhaps someone knows 
> about the pre-content-set filter types - I'm
> definitely not the expert.
> 
> Joe
> 
> John Zhang wrote:
> > In an output filter.  If something is wrong, and I
> set
> > the request object's status to an error code, then
> am
> > I responsible for providing the proper error page
> > content?  What is the correct way to handle errors
> in
> > an output filter?
> >
> > Thanks,
> > John
> >   
> 
> 


Mime
View raw message