From: Christophe Jaillet Date: Fri, 23 Mar 2018 22:01:08 +0000 (+0000) Subject: Add compatibility note for the 3rd argument of 'RewriteMap' X-Git-Tag: 2.5.0-alpha2-ci-test-only~2759 X-Git-Url: http://git.ipfire.org/cgi-bin/gitweb.cgi?a=commitdiff_plain;h=3d74244e79dc2f2192b656d924267060bead0472;p=thirdparty%2Fapache%2Fhttpd.git Add compatibility note for the 3rd argument of 'RewriteMap' (backported in 2.4.x in 1811748) Improve doc highlight git-svn-id: https://svn.apache.org/repos/asf/httpd/httpd/trunk@1827603 13f79535-47bb-0310-9956-ffa450edef68 --- diff --git a/docs/manual/mod/mod_rewrite.xml b/docs/manual/mod/mod_rewrite.xml index d4e984e8df5..ef861039581 100644 --- a/docs/manual/mod/mod_rewrite.xml +++ b/docs/manual/mod/mod_rewrite.xml @@ -307,9 +307,11 @@ LogLevel alert rewrite:trace3 RewriteMap Defines a mapping function for key-lookup RewriteMap MapName MapType:MapSource - MapTypeOptions + [MapTypeOptions] server configvirtual host +The 3rd parameter, MapTypeOptions, in only available from Apache +2.4.30 and later @@ -349,7 +351,7 @@ RewriteMap examplemap "txt:/path/to/file/map.txt"

You would then be able to use this map in a - RewriteRule as follows:

+ RewriteRule as follows:

RewriteRule "^/ex/(.*)" "${examplemap:$1}" @@ -597,7 +599,7 @@ AliasMatch "^/myapp" "/opt/myapp-1.2.3" UseCanonicalPhysicalPort respectively.

-

Those that are special to mod_rewrite include those below.

+

Those that are special to mod_rewrite include those below.

API_VERSION
@@ -750,9 +752,9 @@ AliasMatch "^/myapp" "/opt/myapp-1.2.3" per-server context (httpd.conf file) you must use %{LA-U:REMOTE_USER} - this variable is set by the authorization phases, which come - after the URL translation phase (during which mod_rewrite - operates).

-

On the other hand, because mod_rewrite implements + after the URL translation phase (during which + mod_rewrite operates).

+

On the other hand, because mod_rewrite implements its per-directory context (.htaccess file) via the Fixup phase of the API and because the authorization phases come before this phase, you just can use @@ -987,7 +989,7 @@ RewriteRule "^/images" "-" [F]

You can also set special flags for CondPattern by appending [flags] - as the third argument to the RewriteCond + as the third argument to the RewriteCond directive, where flags is a comma-separated list of any of the following flags:

@@ -1093,8 +1095,8 @@ RewriteRule "^/$" "/homepage.std.html" [L] this context only match against the portion of the currently mapped filesystem path "below" where the rule is defined.

-

Directives such as DocumentRoot and Alias, or even the +

Directives such as DocumentRoot and Alias, or even the result of previous RewriteRule substitutions, determine the currently mapped filesystem path.

@@ -1147,7 +1149,7 @@ to break in these contexts is relative substitutions. the mod_rewrite Introduction.

-

In mod_rewrite, the NOT character +

In mod_rewrite, the NOT character ('!') is also available as a possible pattern prefix. This enables you to negate a pattern; to say, for instance: ``if the current URL does NOT match this @@ -1432,7 +1434,7 @@ cannot use $N in the substitution string! Home directory expansion

When the substitution string begins with a string -resembling "/~user" (via explicit text or backreferences), mod_rewrite performs +resembling "/~user" (via explicit text or backreferences), mod_rewrite performs home directory expansion independent of the presence or configuration of mod_userdir.