]> granicus.if.org Git - apache/commitdiff
Merge r1641888 from trunk:
authorEric Covener <covener@apache.org>
Wed, 26 Nov 2014 19:05:53 +0000 (19:05 +0000)
committerEric Covener <covener@apache.org>
Wed, 26 Nov 2014 19:05:53 +0000 (19:05 +0000)
add a few more expresion examples to illustrate functions and -f

git-svn-id: https://svn.apache.org/repos/asf/httpd/httpd/branches/2.4.x@1641890 13f79535-47bb-0310-9956-ffa450edef68

docs/manual/expr.xml

index 8364b0f8bcbc3739a6520330dd06c0daa8999bb4..1f225ca89e03129b67ce35c049cf6b2dc6240bcb 100644 (file)
@@ -556,6 +556,18 @@ listfunction ::= listfuncname "<strong>(</strong>" word "<strong>)</strong>"
     Header set matched true
 &lt;/If&gt;
 
+# Check an environment variable for a regular expression, negated.
+&lt;If "! reqenv('REDIRECT_FOO') =~ /bar/"&gt;
+    Header set matched true
+&lt;/If&gt;
+
+# Check result of URI mapping by running in Directory context with -f
+&lt;Directory /var/www&gt;
+    AddEncoding x-gzip gz
+&lt;If "-f '%{REQUEST_FILENAME}.unzipme' &amp;&amp; ! %{HTTP:Accept-Encoding} =~ /gzip/"&gt;
+      SetOutputFilter INFLATE
+&lt;/If&gt;
+&lt;/Directory&gt;
 
        </highlight>
 </section>