|
Posted by Qiang on July 28, 2007, 10:36 pm
Please log in for more thread options
Hi,
I tried to use Apache::Filter to modify the HTTP output. It works for
static files, but not for dynamic perl handlers (virtual location). I
am using apache 1.3 and modperl 1. see below httpd.conf configuration.
Is this a configuration issue or Apache::Filter does not support
filtering for dynamic generated stuff?
thanks in advance,
Qiang
## works OK. Get results as desired
PerlModule Apache::Filter
PerlModule MyFilterPkg::MyFilter
<Files ~ (\.htm)>
SetHandler perl-script
PerlSetVar Filter On
PerlHandler MyFilterPkg::MyFilter
</Files>
## It does not work. Server Generates a 404 error
## [Thu Jul 2613:42:32 2007] [error] xxxx/test1 not found
PerlModule Apache::Filter
Perlhandler MyHandlerPkg::TestHandler
PerlModule MyFilterPkg::MyFilter
#location test1 is a virtual location that is handled by a perl
handler
<Location /test1>
SetHandler perl-script
# This is the regular perl handler
Perlhandler MyHandlerPkg::TestHandler
PerlSetVar Filter On
PerlHandler MyFilterPkg::MyFilter
</Location>
#The call to filter_input returns a 404 error too.
my ($fh, $status) = $r->filter_input();
|