On Thu 28 Feb 2008, J. Peng wrote:
> I need to write an input filter based on the request headers.
> If request includes a "Accept-Encoding:=A0gzip, deflate" header, I
> should redirect the request to /pathA.
> If request doesn't include that header, I should redirect the request to
> /pathB. (pathA and pathB are web document dirs on web server.)


I think you don't need an input filter. What you need is a PerlTransHandler=
or=20
a PerlMapToStorageHandler that checks $r->headers_in->{'Accept-Encoding'} a=
nd=20
sets $r->filename and/or $r->uri accordingly.

This can even be done with mod_rewrite.

Torsten