* Vincent Bray wrote:
> On 23/07/07, André Malo <[EMAIL PROTECTED]> wrote: > > Well...... it's not entirely true. It actually matches both. In > > contrast to popular belief the particular word to mind here is > > "current". Within a given set, mod_rewrite matches the current value of > > r->uri or r->filename, I think (depending on server vs. directory > > context) (possibly preparing it before starting matching). It is true > > that it *starts* with the URL path. But it continues with the > > replacement, whatever it is, so: > > > > RewriteRule foo http://bar/baz > > > > writes http://bar/baz into r->something and this is what's going to be > > matched next time. The automatic redirect is detected after the last > > rule of the set (which may rewrite it to something else, so the > > automatic redirect won't happen anymore). Note that some flags even > > change that URL to things like proxy:http://zonk/zapp or > > redirect:http://something/else. > > > > Now, this is hard to explain. :-) > > I have a young daughter and fully expect that birds and bees will be a > doddle by comparison. ;) > So assuming r->something is not in the set [r->uri, r->filename] It's one of those. > something else (perhaps r->parsed_uri?), and that mod_rewrite uses > that as a holding area during its fiddlings, is it possible to rewrite > to a proxy: or balancer: or http: url and then continue past that > point? I thought it wasn't.. It is, if you're doing it explicitly. Most people use [L] though, so it doesn't matter very much. IIRC, if done implicitly, the [P] flag finishs the set, the [R] flag doesn't. But I need to check against the sources as well :-) > I was rather hoping this thread wouldn't involve me trying (once > again) to grok mod_rewrite.c. Oh well, at least there's the pretty > banner :-) > > No easy "[x] that one" fix? Not that easy. I think, explaining the start (URL-path, absolute in server context but relative to the .htaccess in directory context) and mentioning the "current" part for further matches should do. nd --------------------------------------------------------------------- To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
