maard has asked for the wisdom of the Perl Monks concerning the following question:
Hello, brothers in faith!
I have apache2 with mod_perl/mod_php and some php software running on it. And I want to filter request headers for php scripts and filter its output again (both headers and body). php scripts are located under /php_area. The problem is, that if I write
then php scripts stop being processed by mod_php and instead are output as plain php code.<Location /php_area> SetHandler modperl PerlInputFilterHandler My::PHPInputFilter PerlOutputFilterHandler My::PHPOutputFilter </Location>
For now I solved the problem by writing "proxy" response handler, which uses LWP to perform requests to php and give user back what I want (it's much simpler than fix all that php code), but i'm still interested in using filters - is it possible in this situation ?
|
---|
Replies are listed 'Best First'. | |
---|---|
Re: surround PHP with filters
by pileofrogs (Priest) on Dec 30, 2005 at 17:23 UTC | |
Re: surround PHP with filters
by perrin (Chancellor) on Dec 29, 2005 at 19:53 UTC | |
by maard (Pilgrim) on Dec 30, 2005 at 12:00 UTC |