yesterday, I got involved in a conversation
on the mod_perl list about using a
section. of course you can't do this, given the configuration constraints of the directive. however, I had never fully realized the implications
merging until right then.
see, apache actually merges
directives twice - once just prior to the translation phase, then once right after. if you've ever written mod_perl directive handlers then you've probably seen your
routine called twice per-request, which is the manifestation of this feature (it's also mentioned in a book
I've heard about
:). anyway, the docs
(and code) say that the results of the first merge are thrown away, which they are. however, they are not thrown away until after
translation. this means you can peek at what is inside of a
now, of course, the reason you wouldn't want to do that is because some other translation handler can come in and alter the URI and *poof* you're not in the
you thought you were, so it's completely unpredictable. however, it is a pretty cool thing to know, and if you're in complete control of your environment and know what you are doing, then it's a feature that's free to be abused.