Re: Changing Apache configuration for each request

Marcus Don <[email protected]>
Newsgroups gmane.comp.apache.mod-perl
Message-ID <CA6AEF72.6B9C7%[email protected]>
Thank you so much Torston!

I had tried this before, but got this error message...

> Can't locate object method "add_config" via package "Apache2::RequestUtil"

...so I (incorrectly) concluded this function no longer existed and the
documentation was out-of-date. It seems the problem was actually just that I
was using the wrong handler!

Regards

Marcus

 

> On Friday, 12 August 2011 11:38:51 Marcus Don wrote:
>> Please could someone confirm whether what I'm trying to do is possible
>> with mod_perl and, if it is, give some clues as to how?
> 
> see $r->add_config in Apache2::RequestUtil. Best place to do it is a
> PerlMapToStorageHandler (or a PerlFixupHandler if that's not too late).
> Note, however, that <Directory> blocks and .htaccess files are applied by
> the core maptostorage handler that runs after the modperl handler. You
> can shortcut the core handler if your handler returns OK instead of
> DECLINED. In that case your handler has to fill in $r->filename, $r-
>> finfo and perhaps $r->path_info. <Location> blocks are applied just
> after the maptostorage phase. They cannot be skipped.
> 
> Torsten Förtsch
lmpx.com only provides a reader for public news (NNTP) servers. It is not affiliated with the servers or forums shown here and is not responsible for the content of articles, which is written by their respective authors.