]> git.ipfire.org Git - thirdparty/apache/httpd.git/commitdiff
Revert r1602714 per http://httpd.apache.org/docs/2.2/howto/ssi.html#comment_2915
authorEric Covener <covener@apache.org>
Fri, 22 Aug 2014 20:31:28 +0000 (20:31 +0000)
committerEric Covener <covener@apache.org>
Fri, 22 Aug 2014 20:31:28 +0000 (20:31 +0000)
which included 2.4/ap_expr info and examples.

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

docs/manual/howto/ssi.xml

index 969d64da90ac6574459cd0695638124fd98c0ce2..0416d8d29893c53c768a781433b39aa1b7ac2075 100644 (file)
@@ -431,30 +431,41 @@ modified?</title>
     the ``truth'' of a particular value. (A given string is true if
     it is nonempty.) For a full list of the comparison operators
     available to you, see the <module>mod_include</module>
-    documentation.</p>
-   
-    <p>For example, if you wish to customize the text on your web page
-    based on the time of day, you could use the following recipe, placed
-    in the HTML page:</p>
-
-    <example>
-    Good
-    &lt;!--#if expr="%{TIME_HOUR} &gt;=12" --&gt;<br />
-    morning!<br />
-    &lt;!--#else --&gt;<br />
-    afternoon!<br />
-    &lt;!--#endif --&gt;<br />
-    </example>
+    documentation. Here are some examples of how one might use this
+    construct.</p>
+
+    <p>In your configuration file, you could put the following
+    line:</p>
+<example>
+        BrowserMatchNoCase macintosh Mac<br />
+        BrowserMatchNoCase MSIE InternetExplorer
+</example>
+
+    <p>This will set environment variables ``Mac'' and
+    ``InternetExplorer'' to true, if the client is running Internet
+    Explorer on a Macintosh.</p>
+
+    <p>Then, in your SSI-enabled document, you might do the
+    following:</p>
+<example>
+        &lt;!--#if expr="${Mac} &amp;&amp; ${InternetExplorer}" --&gt;<br />
+        Apologetic text goes here<br />
+        &lt;!--#else --&gt;<br />
+        Cool JavaScript code goes here<br />
+        &lt;!--#endif --&gt;
+</example>
+
+    <p>Not that I have anything against IE on Macs - I just
+    struggled for a few hours last week trying to get some
+    JavaScript working on IE on a Mac, when it was working
+    everywhere else. The above was the interim workaround.</p>
 
     <p>Any other variable (either ones that you define, or normal
     environment variables) can be used in conditional statements.
-    See <a href="../expr.html">Expressions in Apache HTTP Server</a> for
-    more information on the expression evaluation engine.</p>
-
-    <p>With Apache's ability to set environment variables with the
+    With Apache's ability to set environment variables with the
     <code>SetEnvIf</code> directives, and other related directives,
-    this functionality can let you do a wide variety of dynamic content
-    on the server side without resorting a full web application.</p>
+    this functionality can let you do some pretty involved dynamic
+    stuff without ever resorting to CGI.</p>
 </section>
 </section>