You are viewing a plain text version of this content. The canonical link for it is here.
Posted to cvs@httpd.apache.org by co...@apache.org on 2016/09/17 20:39:45 UTC

svn commit: r1761273 - /httpd/httpd/trunk/docs/manual/expr.html.en

Author: covener
Date: Sat Sep 17 20:39:45 2016
New Revision: 1761273

URL: http://svn.apache.org/viewvc?rev=1761273&view=rev
Log:
xform


Modified:
    httpd/httpd/trunk/docs/manual/expr.html.en

Modified: httpd/httpd/trunk/docs/manual/expr.html.en
URL: http://svn.apache.org/viewvc/httpd/httpd/trunk/docs/manual/expr.html.en?rev=1761273&r1=1761272&r2=1761273&view=diff
==============================================================================
--- httpd/httpd/trunk/docs/manual/expr.html.en (original)
+++ httpd/httpd/trunk/docs/manual/expr.html.en Sat Sep 17 20:39:45 2016
@@ -437,7 +437,7 @@ listfunction ::= listfuncname "<strong>(
     a string. Functions names are not case sensitive.
     Modules may register additional functions.</p>
 
-    <table class="bordered"><tr class="header"><th>Name</th><th>Description</th><th>Restricted</th></tr>
+    <table class="bordered"><tr class="header"><th>Name</th><th>Description</th><th>Special notes</th></tr>
 <tr><td><code>req</code>, <code>http</code></td>
         <td>Get HTTP request header; header names may be added to the Vary
             header, see below</td><td /></tr>
@@ -449,15 +449,16 @@ listfunction ::= listfuncname "<strong>(
             during <code class="directive">&lt;If&gt;</code>)</td><td /></tr>
 <tr class="odd"><td><code>reqenv</code></td>
         <td>Lookup request environment variable (as a shortcut,
-        <code>v</code> can be used too to access
-        variables)</td><td /></tr>
+        <code>v</code> can also be used to access variables). 
+        </td>
+        <td>ordering</td></tr>
 <tr><td><code>osenv</code></td>
         <td>Lookup operating system environment variable</td><td /></tr>
 <tr class="odd"><td><code>note</code></td>
-        <td>Lookup request note</td><td /></tr>
+        <td>Lookup request note</td><td>ordering</td></tr>
 <tr><td><code>env</code></td>
         <td>Return first match of <code>note</code>, <code>reqenv</code>,
-            <code>osenv</code></td><td /></tr>
+            <code>osenv</code></td><td>ordering</td></tr>
 <tr class="odd"><td><code>tolower</code></td>
         <td>Convert string to lower case</td><td /></tr>
 <tr><td><code>toupper</code></td>
@@ -480,13 +481,13 @@ listfunction ::= listfuncname "<strong>(
             encoding</td><td /></tr>
 <tr class="odd"><td><code>file</code></td>
         <td>Read contents from a file (including line endings, when present)
-        </td><td>yes</td></tr>
+        </td><td>restricted</td></tr>
 <tr><td><code>filemod</code></td>
         <td>Return last modification time of a file (or 0 if file does not exist
-            or is not regular file)</td><td>yes</td></tr>
+            or is not regular file)</td><td>restricted</td></tr>
 <tr class="odd"><td><code>filesize</code></td>
         <td>Return size of a file (or 0 if file does not exist or is not
-            regular file)</td><td>yes</td></tr>
+            regular file)</td><td>restricted</td></tr>
 <tr><td><code>ldap</code></td>
         <td>Escape characters as required by LDAP distinguished name escaping
             (RFC4514) and LDAP filter escaping (RFC4515).</td><td /></tr>
@@ -495,8 +496,28 @@ listfunction ::= listfuncname "<strong>(
             in the string with "to".</td><td /></tr>
 </table>
 
-    <p>The functions marked as "restricted" are not available in some modules
-    like <code class="module"><a href="./mod/mod_include.html">mod_include</a></code>.</p>
+    <p>The functions marked as "restricted" in the final column are not 
+    available in some modules like <code class="module"><a href="./mod/mod_include.html">mod_include</a></code>.</p>
+
+    <p>The functions marked as "ordering" in the final column require some
+    consideration for the ordering of different components of the server,
+    especially when the function is used within the 
+    &lt;<code class="directive"><a href="./mod/core.html#if">If</a></code>&gt; directive which is
+    evaluated relatively early.</p>
+    <div class="note">
+    <h3>Environment variable ordering</h3>
+    When environment variables are looked up within an 
+    &lt;<code class="directive"><a href="./mod/core.html#if">If</a></code>&gt; condition, it's important 
+    to consider how extremely early in request processing that this 
+    resolution occurs. As a guideline, any directive defined outside of virtual host 
+    context (directory, location, htaccess) is not likely to have yet had a 
+    chance to execute. <code class="directive"><a href="./mod/mod_setenvif.html#setenvif">SetEnvIf</a></code>
+    in virtual host scope is one directive that runs prior to this resolution
+    <br />
+    <br />
+    When <code>reqenv</code> is used outside of &lt;<code class="directive"><a href="./mod/core.html#if">If</a></code>&gt;, the resolution will generally occur later, but the 
+    exact timing depends on the directive the expression has been used within.
+    </div>
 
     <p>When the functions <code>req</code> or <code>http</code> are used,
     the header name will automatically be added to the Vary header of the