httpd-bugs mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
Subject DO NOT REPLY [Bug 44838] New: mod_rewrite documentation is not explicit about rewrite context
Date Thu, 17 Apr 2008 22:56:24 GMT

           Summary: mod_rewrite documentation is not explicit about rewrite
           Product: Apache httpd-2
           Version: 2.3-HEAD
          Platform: All
        OS/Version: All
            Status: NEW
          Severity: normal
          Priority: P2
         Component: Documentation

mod_rewrite is fed different things depending on the context of the rules and
the official documentation is not explicit about this. Compare:

"Never forget that Pattern is applied to a complete URL in per-server
configuration files. However, in per-directory configuration files, the
per-directory prefix (which always is the same for a specific directory) is
automatically removed for the pattern matching and automatically added after
the substitution has been done. This feature is essential for many sorts of
rewriting - without this, you would always have to match the parent directory
which is not always possible."

"The Apache HTTPD Server deals with requests in discrete phases. While this is
usually transparent to the user and administrator it does have an effect on the
behaviour of mod_rewrite when rulesets are placed in different contexts. To
oversimplify a little, when rules are placed in VirtualHost blocks (or in the
main server context) they get evaluated before the server has yet mapped the
requested URI to a filesystem path. Conversely, when rules are placed in
.htaccess files, or in Directory blocks in the main server config, they are
evaluated after this phase has occured."

I think that the first URI should mention explicitly (or at least be as clear
as the Wiki is) that the RewriteRule directive is fed either the request URI or
the mapped filename depending on context.

Configure bugmail:
------- You are receiving this mail because: -------
You are the assignee for the bug.

To unsubscribe, e-mail:
For additional commands, e-mail:

View raw message