mod_include.xml revision b115299831a7b4bbec58a88d708d8536e1ecd50c
97a9a944b5887e91042b019776c41d5dd74557aferikabele<!DOCTYPE modulesynopsis SYSTEM "/style/modulesynopsis.dtd">
97a9a944b5887e91042b019776c41d5dd74557aferikabele<?xml-stylesheet type="text/xsl" href="/style/manual.en.xsl"?>
b1ced323143ade589985456a78f3f64d6a6580c5yoshiki<!-- $LastChangedRevision$ -->
0c4abc32c00611fe1d52c9661f5cc79a3f74c6d4nd Licensed to the Apache Software Foundation (ASF) under one or more
0c4abc32c00611fe1d52c9661f5cc79a3f74c6d4nd contributor license agreements. See the NOTICE file distributed with
0c4abc32c00611fe1d52c9661f5cc79a3f74c6d4nd this work for additional information regarding copyright ownership.
0c4abc32c00611fe1d52c9661f5cc79a3f74c6d4nd The ASF licenses this file to You under the Apache License, Version 2.0
d29d9ab4614ff992b0e8de6e2b88d52b6f1f153erbowen (the "License"); you may not use this file except in compliance with
d29d9ab4614ff992b0e8de6e2b88d52b6f1f153erbowen the License. You may obtain a copy of the License at
0c4abc32c00611fe1d52c9661f5cc79a3f74c6d4nd Unless required by applicable law or agreed to in writing, software
0c4abc32c00611fe1d52c9661f5cc79a3f74c6d4nd distributed under the License is distributed on an "AS IS" BASIS,
0c4abc32c00611fe1d52c9661f5cc79a3f74c6d4nd WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
3f08db06526d6901aa08c110b5bc7dde6bc39905nd See the License for the specific language governing permissions and
0c4abc32c00611fe1d52c9661f5cc79a3f74c6d4nd limitations under the License.
3b3b7fc78d1f5bfc2769903375050048ff41ff26nd<description>Server-parsed html documents (Server Side Includes)</description>
0c4abc32c00611fe1d52c9661f5cc79a3f74c6d4nd<compatibility>Implemented as an output filter since Apache
0c4abc32c00611fe1d52c9661f5cc79a3f74c6d4nd2.0</compatibility>
cea021a7fc2657b091df4d3b031c4254ec371dd7rbowen <p>This module provides a filter which will process files
0c4abc32c00611fe1d52c9661f5cc79a3f74c6d4nd before they are sent to the client. The processing is
0c4abc32c00611fe1d52c9661f5cc79a3f74c6d4nd controlled by specially formatted SGML comments, referred to as
9a58dc6a2b26ec128b1270cf48810e705f1a90dbsf <dfn>elements</dfn>. These elements allow conditional text, the
f19fa851b976a05691dea05be46586aa5aadeba2rbowen inclusion of other files or programs, as well as the setting and
9a58dc6a2b26ec128b1270cf48810e705f1a90dbsf printing of environment variables.</p>
f6445f3ad1c82f9398dc8edd77093cd3e20b806cnoirin<seealso><directive module="core">Options</directive></seealso>
9a58dc6a2b26ec128b1270cf48810e705f1a90dbsf<seealso><directive module="core">AcceptPathInfo</directive></seealso>
f6445f3ad1c82f9398dc8edd77093cd3e20b806cnoirin<seealso><a href="/howto/ssi.html">SSI Tutorial</a></seealso>
9a58dc6a2b26ec128b1270cf48810e705f1a90dbsf <p>Server Side Includes are implemented by the
9a58dc6a2b26ec128b1270cf48810e705f1a90dbsf <code>INCLUDES</code> <a href="/filter.html">filter</a>. If
9a58dc6a2b26ec128b1270cf48810e705f1a90dbsf documents containing server-side include directives are given
f6445f3ad1c82f9398dc8edd77093cd3e20b806cnoirin the extension .shtml, the following directives will make Apache
06ba4a61654b3763ad65f52283832ebf058fdf1cslive parse them and assign the resulting document the mime type of
0c4abc32c00611fe1d52c9661f5cc79a3f74c6d4nd AddOutputFilter INCLUDES .shtml
0c4abc32c00611fe1d52c9661f5cc79a3f74c6d4nd </example>
117c1f888a14e73cdd821dc6c23eb0411144a41cnd <p>The following directive must be given for the directories
117c1f888a14e73cdd821dc6c23eb0411144a41cnd containing the shtml files (typically in a
117c1f888a14e73cdd821dc6c23eb0411144a41cnd <directive module="core" type="section">Directory</directive> section,
117c1f888a14e73cdd821dc6c23eb0411144a41cnd but this directive is also valid in <code>.htaccess</code> files if
0c4abc32c00611fe1d52c9661f5cc79a3f74c6d4nd <directive module="core">AllowOverride</directive> <code>Options</code>
b41a0dbe6310c576e96b7ea6910051fd84fb06f5sf is set):</p>
b41a0dbe6310c576e96b7ea6910051fd84fb06f5sf Options +Includes
b41a0dbe6310c576e96b7ea6910051fd84fb06f5sf </example>
7571ea383299910bead3e93e66246cb212a28d0figalic <p>For backwards compatibility, the <code>server-parsed</code>
b41a0dbe6310c576e96b7ea6910051fd84fb06f5sf INCLUDES filter. As well, Apache will activate the INCLUDES
b41a0dbe6310c576e96b7ea6910051fd84fb06f5sf filter for any document with mime type
b41a0dbe6310c576e96b7ea6910051fd84fb06f5sf <code>text/x-server-parsed-html3</code> (and the resulting
b41a0dbe6310c576e96b7ea6910051fd84fb06f5sf output will have the mime type <code>text/html</code>).</p>
b41a0dbe6310c576e96b7ea6910051fd84fb06f5sf href="/howto/ssi.html">Tutorial on Server Side Includes</a>.</p>
e487d6c09669296f94a5190cc34586a98e624a00nd <p>Files processed for server-side includes no longer accept
1e6708ac9aebbbd0ff63c2b93e6b97d50263a8bbrbowen requests with <code>PATH_INFO</code> (trailing pathname information)
17ade6df5ec233536985eb1c130a906c725dd614humbedooh by default. You can use the <directive
f6445f3ad1c82f9398dc8edd77093cd3e20b806cnoirin configure the server to accept requests with <code>PATH_INFO</code>.</p>
9b3696c7ad70387ecd46e0f061b99d381dc392f9rbowen <p>The document is parsed as an HTML document, with special
9b3696c7ad70387ecd46e0f061b99d381dc392f9rbowen commands embedded as SGML comments. A command has the syntax: </p>
9b3696c7ad70387ecd46e0f061b99d381dc392f9rbowen <!--#<var>element</var> <var>attribute</var>=<var>value</var>
9b3696c7ad70387ecd46e0f061b99d381dc392f9rbowen <p>The value will often be enclosed in double quotes, but single
9b3696c7ad70387ecd46e0f061b99d381dc392f9rbowen quotes (<code>'</code>) and backticks (<code>`</code>) are also
9b3696c7ad70387ecd46e0f061b99d381dc392f9rbowen possible. Many commands only allow a single attribute-value pair.
9b3696c7ad70387ecd46e0f061b99d381dc392f9rbowen Note that the comment terminator (<code>--></code>) should be
b41a0dbe6310c576e96b7ea6910051fd84fb06f5sf preceded by whitespace to ensure that it isn't considered part of
0c4abc32c00611fe1d52c9661f5cc79a3f74c6d4nd an SSI token. Note that the leading <code><!--#</code> is <em>one</em>
0c4abc32c00611fe1d52c9661f5cc79a3f74c6d4nd token and may not contain any whitespaces.</p>
0c4abc32c00611fe1d52c9661f5cc79a3f74c6d4nd <p>The allowed elements are listed in the following table:</p>
0c4abc32c00611fe1d52c9661f5cc79a3f74c6d4nd <tr><td><code><a href="#element.config">config</a></code></td>
0c4abc32c00611fe1d52c9661f5cc79a3f74c6d4nd <tr><td><code><a href="#element.echo">echo</a></code></td>
06f0540592b1d6fc148e1ec9afc95ce48162db18covener <tr><td><code><a href="#element.exec">exec</a></code></td>
06f0540592b1d6fc148e1ec9afc95ce48162db18covener <tr><td><code><a href="#element.fsize">fsize</a></code></td>
06f0540592b1d6fc148e1ec9afc95ce48162db18covener <tr><td><code><a href="#element.flastmod">flastmod</a></code></td>
06f0540592b1d6fc148e1ec9afc95ce48162db18covener <td>print last modification time of a file</td></tr>
b9bf3918f6eaf7747bcbfbd02792bcbe4a052784nilgun <tr><td><code><a href="#element.include">include</a></code></td>
06f0540592b1d6fc148e1ec9afc95ce48162db18covener <tr><td><code><a href="#element.printenv">printenv</a></code></td>
06f0540592b1d6fc148e1ec9afc95ce48162db18covener <tr><td><code><a href="#element.set">set</a></code></td>
06f0540592b1d6fc148e1ec9afc95ce48162db18covener <p>SSI elements may be defined by modules other than
06f0540592b1d6fc148e1ec9afc95ce48162db18covener href="#element.exec">exec</a></code> element is provided by
635de20c16ef862bfc5b0d5f9ceb40ebeaddfdf3noirin <module>mod_cgi</module>, and will only be available if this
06f0540592b1d6fc148e1ec9afc95ce48162db18covener module is loaded.</p>
06f0540592b1d6fc148e1ec9afc95ce48162db18covener <section id="element.config"><title>The config Element</title>
06f0540592b1d6fc148e1ec9afc95ce48162db18covener <p>This command controls various aspects of the parsing. The
06f0540592b1d6fc148e1ec9afc95ce48162db18covener valid attributes are:</p>
06f0540592b1d6fc148e1ec9afc95ce48162db18covener <dt><code>echomsg</code> (<em>Apache 2.1 and later</em>)</dt>
06f0540592b1d6fc148e1ec9afc95ce48162db18covener <dd>The value is a message that is sent back to the
17ade6df5ec233536985eb1c130a906c725dd614humbedooh client if the <code><a href="#element.echo">echo</a></code> element
17ade6df5ec233536985eb1c130a906c725dd614humbedooh attempts to echo an undefined variable. This overrides any <directive
17ade6df5ec233536985eb1c130a906c725dd614humbedooh module="mod_include">SSIUndefinedEcho</directive> directives.</dd>
17ade6df5ec233536985eb1c130a906c725dd614humbedooh <dd>The value is a message that is sent back to the
06ba4a61654b3763ad65f52283832ebf058fdf1cslive client if an error occurs while parsing the
0c4abc32c00611fe1d52c9661f5cc79a3f74c6d4nd document. This overrides any <directive
0c4abc32c00611fe1d52c9661f5cc79a3f74c6d4nd module="mod_include">SSIErrorMsg</directive> directives.</dd>
0c4abc32c00611fe1d52c9661f5cc79a3f74c6d4nd <dd>The value sets the format to be used when displaying
0c4abc32c00611fe1d52c9661f5cc79a3f74c6d4nd in Kb or Mb as appropriate, for example a size of 1024 bytes
0c4abc32c00611fe1d52c9661f5cc79a3f74c6d4nd will be printed as "1K".</dd>
0c4abc32c00611fe1d52c9661f5cc79a3f74c6d4nd <dd>The value is a string to be used by the
fa0f379e3845907d7c1087d885169e302239bdbbnd dates.</dd>
fa0f379e3845907d7c1087d885169e302239bdbbnd <section id="element.echo"><title>The echo Element</title>
fa0f379e3845907d7c1087d885169e302239bdbbnd <p>This command prints one of the <a href="#includevars">include
fa0f379e3845907d7c1087d885169e302239bdbbnd variables</a> defined below. If the variable is unset, the result is
fa0f379e3845907d7c1087d885169e302239bdbbnd >SSIUndefinedEcho</directive> directive. Any dates printed are
06ba4a61654b3763ad65f52283832ebf058fdf1cslive subject to the currently configured <code>timefmt</code>.</p>
fa0f379e3845907d7c1087d885169e302239bdbbnd <dd><p>Specifies how Apache should encode special characters
06ba4a61654b3763ad65f52283832ebf058fdf1cslive contained in the variable before outputting them. If set
06ba4a61654b3763ad65f52283832ebf058fdf1cslive to <code>none</code>, no encoding will be done. If set to
bf380c59be3f235bde21f1c00098e09e3cf7e7aerpluem <code>url</code>, then URL encoding (also known as %-encoding;
b115299831a7b4bbec58a88d708d8536e1ecd50csf this is appropriate for use within URLs in links, etc.) will be
fa0f379e3845907d7c1087d885169e302239bdbbnd the default is set to <code>entity</code>, resulting in entity
b115299831a7b4bbec58a88d708d8536e1ecd50csf encoding (which is appropriate in the context of a block-level
b115299831a7b4bbec58a88d708d8536e1ecd50csf HTML element, <em>e.g.</em> a paragraph of text). This can be
fa0f379e3845907d7c1087d885169e302239bdbbnd changed by adding an <code>encoding</code> attribute, which will
06ba4a61654b3763ad65f52283832ebf058fdf1cslive remain in effect until the next <code>encoding</code> attribute
06ba4a61654b3763ad65f52283832ebf058fdf1cslive is encountered or the element ends, whichever comes first.</p>
fa0f379e3845907d7c1087d885169e302239bdbbnd <p>The <code>encoding</code> attribute must <em>precede</em> the
fa0f379e3845907d7c1087d885169e302239bdbbnd corresponding <code>var</code> attribute to be effective, and
06ba4a61654b3763ad65f52283832ebf058fdf1cslive only special characters as defined in the ISO-8859-1 character
06ba4a61654b3763ad65f52283832ebf058fdf1cslive encoding will be encoded. This encoding process may not have the
fa0f379e3845907d7c1087d885169e302239bdbbnd desired result if a different character encoding is in use.</p>
fa0f379e3845907d7c1087d885169e302239bdbbnd In order to avoid cross-site scripting issues, you should
97a9a944b5887e91042b019776c41d5dd74557aferikabele <section id="element.exec"><title>The exec Element</title>
5ae30adbe59946de742ab0cd6be3b7457471a698takashi <p>The <code>exec</code> command executes a given shell command or
97a9a944b5887e91042b019776c41d5dd74557aferikabele CGI script. It requires <module>mod_cgi</module> to be present
97a9a944b5887e91042b019776c41d5dd74557aferikabele in the server. If <directive module="core">Options</directive>
5ae30adbe59946de742ab0cd6be3b7457471a698takashi <code>IncludesNOEXEC</code> is set, this command is completely
5ae30adbe59946de742ab0cd6be3b7457471a698takashi disabled. The valid attributes are:</p>
97a9a944b5887e91042b019776c41d5dd74557aferikabele <dd><p>The value specifies a (%-encoded) URL-path to
97a9a944b5887e91042b019776c41d5dd74557aferikabele the CGI script. If the path does not begin with a slash (/),
97a9a944b5887e91042b019776c41d5dd74557aferikabele then it is taken to be relative to the current
06ba4a61654b3763ad65f52283832ebf058fdf1cslive document. The document referenced by this path is
06ba4a61654b3763ad65f52283832ebf058fdf1cslive invoked as a CGI script, even if the server would not
06ba4a61654b3763ad65f52283832ebf058fdf1cslive normally recognize it as such. However, the directory
97a9a944b5887e91042b019776c41d5dd74557aferikabele containing the script must be enabled for CGI scripts
97a9a944b5887e91042b019776c41d5dd74557aferikabele (with <directive module="mod_alias">ScriptAlias</directive>
97a9a944b5887e91042b019776c41d5dd74557aferikabele <p>The CGI script is given the <code>PATH_INFO</code> and query
97a9a944b5887e91042b019776c41d5dd74557aferikabele string (<code>QUERY_STRING</code>) of the original request from the
97a9a944b5887e91042b019776c41d5dd74557aferikabele client; these <em>cannot</em> be specified in the URL path. The
97a9a944b5887e91042b019776c41d5dd74557aferikabele include variables will be available to the script in addition to
97a9a944b5887e91042b019776c41d5dd74557aferikabele the standard <a href="mod_cgi.html">CGI</a> environment.</p>
06ba4a61654b3763ad65f52283832ebf058fdf1cslive <p>If the script returns a <code>Location:</code> header instead of
53d2fd50ff45e7c568f0588c742a5ef9edf8e275rbowen output, then this will be translated into an HTML anchor.</p>
97a9a944b5887e91042b019776c41d5dd74557aferikabele <p>The <code><a href="#includevirtual">include virtual</a></code>
97a9a944b5887e91042b019776c41d5dd74557aferikabele element should be used in preference to <code>exec cgi</code>. In
5ae30adbe59946de742ab0cd6be3b7457471a698takashi particular, if you need to pass additional arguments to a CGI program,
5ae30adbe59946de742ab0cd6be3b7457471a698takashi using the query string, this cannot be done with <code>exec
97a9a944b5887e91042b019776c41d5dd74557aferikabele cgi</code>, but can be done with <code>include virtual</code>, as
97a9a944b5887e91042b019776c41d5dd74557aferikabele shown here:</p>
97a9a944b5887e91042b019776c41d5dd74557aferikabele <!--#include virtual="/cgi-bin/example.cgi?argument=value" -->
97a9a944b5887e91042b019776c41d5dd74557aferikabele <dd><p>The server will execute the given string using
97a9a944b5887e91042b019776c41d5dd74557aferikabele >include variables</a> are available to the command, in addition
97a9a944b5887e91042b019776c41d5dd74557aferikabele to the usual set of CGI variables.</p>
97a9a944b5887e91042b019776c41d5dd74557aferikabele >#include virtual</a></code> is almost always prefered to using
97a9a944b5887e91042b019776c41d5dd74557aferikabele either <code>#exec cgi</code> or <code>#exec cmd</code>. The former
06ba4a61654b3763ad65f52283832ebf058fdf1cslive (<code>#include virtual</code>) uses the standard Apache sub-request
06ba4a61654b3763ad65f52283832ebf058fdf1cslive mechanism to include files or scripts. It is much better tested and
06ba4a61654b3763ad65f52283832ebf058fdf1cslive maintained.</p>
97a9a944b5887e91042b019776c41d5dd74557aferikabele <p>In addition, on some platforms, like Win32, and on unix when
97a9a944b5887e91042b019776c41d5dd74557aferikabele using <a href="/suexec.html">suexec</a>, you cannot pass arguments
97a9a944b5887e91042b019776c41d5dd74557aferikabele to a command in an <code>exec</code> directive, or otherwise include
97a9a944b5887e91042b019776c41d5dd74557aferikabele spaces in the command. Thus, while the following will work under a
fb82af0f0cd7b58eef19c54b086131b7e1e1e749madhum non-suexec configuration on unix, it will not produce the desired
4203a35c28d7c60adb7e9ef3be87aad34951c79asf result under Win32, or when running suexec:</p>
06ba4a61654b3763ad65f52283832ebf058fdf1cslive <!--#exec cmd="perl /path/to/perlscript arg1 arg2" -->
fa0f379e3845907d7c1087d885169e302239bdbbnd </example>
fa0f379e3845907d7c1087d885169e302239bdbbnd <section id="element.fsize"><title>The fsize Element</title>
37ef4b86270a8e58f87aa5fe558e3e65af97991ccovener <p>This command prints the size of the specified file, subject
37ef4b86270a8e58f87aa5fe558e3e65af97991ccovener to the <code>sizefmt</code> format specification. Attributes:</p>
37ef4b86270a8e58f87aa5fe558e3e65af97991ccovener <dd>The value is a path relative to the directory
37ef4b86270a8e58f87aa5fe558e3e65af97991ccovener containing the current document being parsed.</dd>
06ba4a61654b3763ad65f52283832ebf058fdf1cslive <dd>The value is a (%-encoded) URL-path. If it does not begin with
06ba4a61654b3763ad65f52283832ebf058fdf1cslive a slash (/) then it is taken to be relative to the current document.
06ba4a61654b3763ad65f52283832ebf058fdf1cslive Note, that this does <em>not</em> print the size of any CGI output,
fa0f379e3845907d7c1087d885169e302239bdbbnd but the size of the CGI script itself.</dd>
06ba4a61654b3763ad65f52283832ebf058fdf1cslive <section id="element.flastmod"><title>The flastmod Element</title>
06ba4a61654b3763ad65f52283832ebf058fdf1cslive <p>This command prints the last modification date of the
06ba4a61654b3763ad65f52283832ebf058fdf1cslive specified file, subject to the <code>timefmt</code> format
06ba4a61654b3763ad65f52283832ebf058fdf1cslive specification. The attributes are the same as for the
cea021a7fc2657b091df4d3b031c4254ec371dd7rbowen <code><a href="#element.fsize">fsize</a></code> command.</p>
fa0f379e3845907d7c1087d885169e302239bdbbnd <section id="element.include"><title>The include Element</title>
cea021a7fc2657b091df4d3b031c4254ec371dd7rbowen <p>This command inserts the text of another document or file
cea021a7fc2657b091df4d3b031c4254ec371dd7rbowen into the parsed file. Any included file is subject to the usual
fa0f379e3845907d7c1087d885169e302239bdbbnd access control. If the directory containing the parsed file has
06ba4a61654b3763ad65f52283832ebf058fdf1cslive <code>IncludesNOEXEC</code> set, then only documents with a text
06ba4a61654b3763ad65f52283832ebf058fdf1cslive <glossary>MIME-type</glossary> (<code>text/plain</code>,
06ba4a61654b3763ad65f52283832ebf058fdf1cslive <code>text/html</code> etc.) will be included. Otherwise CGI
06ba4a61654b3763ad65f52283832ebf058fdf1cslive scripts are invoked as normal using the complete URL given in
06ba4a61654b3763ad65f52283832ebf058fdf1cslive the command, including any query string.</p>
06ba4a61654b3763ad65f52283832ebf058fdf1cslive <p>An attribute defines the location of the document; the
9a58dc6a2b26ec128b1270cf48810e705f1a90dbsf inclusion is done for each attribute given to the include
777c17c11c2b1638f191241364e034779851d186covener command. The valid attributes are:</p>
0844fff26cb7719e0f0a368d88544156ed6374b6sf <dd>The value is a path relative to the directory
0844fff26cb7719e0f0a368d88544156ed6374b6sf containing the current document being parsed. It cannot
0844fff26cb7719e0f0a368d88544156ed6374b6sf contain <code>../</code>, nor can it be an absolute path.
0844fff26cb7719e0f0a368d88544156ed6374b6sf Therefore, you cannot include files that are outside of the
06ba4a61654b3763ad65f52283832ebf058fdf1cslive document root, or above the current document in the directory
06ba4a61654b3763ad65f52283832ebf058fdf1cslive structure. The <code>virtual</code> attribute should always be
06ba4a61654b3763ad65f52283832ebf058fdf1cslive used in preference to this one.</dd>
c0a201f9f0cda37f4e5829462c7e489f85bf327ccovener <dt><code><a id="includevirtual" name="includevirtual"
9a58dc6a2b26ec128b1270cf48810e705f1a90dbsf <dd><p>The value is a (%-encoded) URL-path. The URL cannot contain a
9a58dc6a2b26ec128b1270cf48810e705f1a90dbsf scheme or hostname, only a path and an optional query string. If it
c0a201f9f0cda37f4e5829462c7e489f85bf327ccovener does not begin with a slash (/) then it is taken to be relative to the
eaaa852423e42d6d86bcada80ed781a205fc3e5fnd current document.</p>
eaaa852423e42d6d86bcada80ed781a205fc3e5fnd <p>A URL is constructed from the attribute, and the output the
fa0f379e3845907d7c1087d885169e302239bdbbnd server would return if the URL were accessed by the client is
fa0f379e3845907d7c1087d885169e302239bdbbnd included in the parsed output. Thus included files can be nested.</p>
fa0f379e3845907d7c1087d885169e302239bdbbnd <p>If the specified URL is a CGI program, the program will be
eaaa852423e42d6d86bcada80ed781a205fc3e5fnd executed and its output inserted in place of the directive in the
4203a35c28d7c60adb7e9ef3be87aad34951c79asf parsed file. You may include a query string in a CGI url:</p>
4203a35c28d7c60adb7e9ef3be87aad34951c79asf <!--#include virtual="/cgi-bin/example.cgi?argument=value" -->
4203a35c28d7c60adb7e9ef3be87aad34951c79asf </example>
06ba4a61654b3763ad65f52283832ebf058fdf1cslive <p><code>include virtual</code> should be used in preference
97a9a944b5887e91042b019776c41d5dd74557aferikabele to <code>exec cgi</code> to include the output of CGI programs
fa0f379e3845907d7c1087d885169e302239bdbbnd into an HTML document.</p>
fa0f379e3845907d7c1087d885169e302239bdbbnd <p>If the <directive module="mod_request">KeptBodySize</directive>
4cb65c31bc681540ea623e1cb2bdd09749fb8d7esf directive is correctly configured and valid for this included
c0c1f9ffbf550e6ba5e60d2d0ee55490794f3aefrbowen file, attempts to POST requests to the enclosing HTML document
4cb65c31bc681540ea623e1cb2bdd09749fb8d7esf will be passed through to subrequests as POST requests as well.
4cb65c31bc681540ea623e1cb2bdd09749fb8d7esf Without the directive, all subrequests are processed as GET
fa0f379e3845907d7c1087d885169e302239bdbbnd requests.</p>
06ba4a61654b3763ad65f52283832ebf058fdf1cslive <section id="element.printenv"><title>The printenv Element</title>
cea021a7fc2657b091df4d3b031c4254ec371dd7rbowen <p>This prints out a listing of all existing variables and
fa0f379e3845907d7c1087d885169e302239bdbbnd their values. Special characters are entity encoded (see the <code><a
fa0f379e3845907d7c1087d885169e302239bdbbnd href="#element.echo">echo</a></code> element for details)
fa0f379e3845907d7c1087d885169e302239bdbbnd before being output. There are no attributes.</p>
fa0f379e3845907d7c1087d885169e302239bdbbnd <!--#printenv -->
fa0f379e3845907d7c1087d885169e302239bdbbnd </example>
cea021a7fc2657b091df4d3b031c4254ec371dd7rbowen <!--#set var="category" value="help" -->
fa0f379e3845907d7c1087d885169e302239bdbbnd <p>In addition to the variables in the standard CGI environment,
fa0f379e3845907d7c1087d885169e302239bdbbnd these are available for the <code>echo</code> command, for
fa0f379e3845907d7c1087d885169e302239bdbbnd <code>if</code> and <code>elif</code>, and to any program
fa0f379e3845907d7c1087d885169e302239bdbbnd invoked by the document.</p>
fa0f379e3845907d7c1087d885169e302239bdbbnd <dd>The filename (excluding directories) of the document
fa0f379e3845907d7c1087d885169e302239bdbbnd requested by the user.</dd>
fa0f379e3845907d7c1087d885169e302239bdbbnd <dd>The (%-decoded) URL path of the document requested by the
fa0f379e3845907d7c1087d885169e302239bdbbnd user. Note that in the case of nested include files, this is
bf380c59be3f235bde21f1c00098e09e3cf7e7aerpluem <em>not</em> the URL for the current document. Note also that
fa0f379e3845907d7c1087d885169e302239bdbbnd module="mod_dir">directoryindex</directive>), the modified
fa0f379e3845907d7c1087d885169e302239bdbbnd URL is shown.</dd>
fa0f379e3845907d7c1087d885169e302239bdbbnd <dd>The last modification date of the document requested by
fa0f379e3845907d7c1087d885169e302239bdbbnd the user.</dd>
fa0f379e3845907d7c1087d885169e302239bdbbnd <dd>If a query string is present, this variable contains the
fa0f379e3845907d7c1087d885169e302239bdbbnd (%-decoded) query string, which is <em>escaped</em> for shell
fa0f379e3845907d7c1087d885169e302239bdbbnd usage (special characters like <code>&</code> etc. are
fa0f379e3845907d7c1087d885169e302239bdbbnd preceded by backslashes).</dd>
fa0f379e3845907d7c1087d885169e302239bdbbnd<section id="substitution"><title>Variable Substitution</title>
fa0f379e3845907d7c1087d885169e302239bdbbnd <p>Variable substitution is done within quoted strings in most
fa0f379e3845907d7c1087d885169e302239bdbbnd cases where they may reasonably occur as an argument to an SSI
fa0f379e3845907d7c1087d885169e302239bdbbnd <code>exec</code>, <code>flastmod</code>, <code>fsize</code>,
fa0f379e3845907d7c1087d885169e302239bdbbnd <code>include</code>, <code>echo</code>, and <code>set</code>
06ba4a61654b3763ad65f52283832ebf058fdf1cslive directives, as well as the arguments to conditional operators.
06ba4a61654b3763ad65f52283832ebf058fdf1cslive You can insert a literal dollar sign into the string using backslash
bf380c59be3f235bde21f1c00098e09e3cf7e7aerpluem quoting:</p>
06ba4a61654b3763ad65f52283832ebf058fdf1cslive <!--#if expr="$a = \$test" -->
88f586e767b7b224bdb1a178455668a2475cfc75rbowen <p>If a variable reference needs to be substituted in the
88f586e767b7b224bdb1a178455668a2475cfc75rbowen middle of a character sequence that might otherwise be
88f586e767b7b224bdb1a178455668a2475cfc75rbowen considered a valid identifier in its own right, it can be
06ba4a61654b3763ad65f52283832ebf058fdf1cslive disambiguated by enclosing the reference in braces,
06ba4a61654b3763ad65f52283832ebf058fdf1cslive <!--#set var="Zed" value="${REMOTE_HOST}_${REQUEST_METHOD}" -->
88f586e767b7b224bdb1a178455668a2475cfc75rbowen <p>This will result in the <code>Zed</code> variable being set
bf380c59be3f235bde21f1c00098e09e3cf7e7aerpluem <p>The below example will print "in foo" if the
bf380c59be3f235bde21f1c00098e09e3cf7e7aerpluem <code>DOCUMENT_URI</code> is <code>/foo/file.html</code>, "in bar"
bf380c59be3f235bde21f1c00098e09e3cf7e7aerpluem if it is <code>/bar/file.html</code> and "in neither" otherwise:</p>
bf380c59be3f235bde21f1c00098e09e3cf7e7aerpluem <!--#if expr='"$DOCUMENT_URI" = "/foo/file.html"' --><br />
bf380c59be3f235bde21f1c00098e09e3cf7e7aerpluem in foo<br />
bf380c59be3f235bde21f1c00098e09e3cf7e7aerpluem <!--#elif expr='"$DOCUMENT_URI" = "/bar/file.html"' --><br />
06ba4a61654b3763ad65f52283832ebf058fdf1cslive in bar<br />
97a9a944b5887e91042b019776c41d5dd74557aferikabele <!--#else --><br />
bf380c59be3f235bde21f1c00098e09e3cf7e7aerpluem in neither<br />
bf380c59be3f235bde21f1c00098e09e3cf7e7aerpluem <!--#endif -->
3b1807171c3f06d8951da1bf23c5f51961c274bbrbowen <!--#if expr="<var>test_condition</var>" --><br />
3b1807171c3f06d8951da1bf23c5f51961c274bbrbowen <!--#elif expr="<var>test_condition</var>" --><br />
3b1807171c3f06d8951da1bf23c5f51961c274bbrbowen <!--#else --><br />
3b1807171c3f06d8951da1bf23c5f51961c274bbrbowen <!--#endif -->
3b1807171c3f06d8951da1bf23c5f51961c274bbrbowen <p>The <code>if</code> element works like an if statement in a
3b1807171c3f06d8951da1bf23c5f51961c274bbrbowen programming language. The test condition is evaluated and if
3b1807171c3f06d8951da1bf23c5f51961c274bbrbowen the result is true, then the text until the next <code>elif</code>,
3b1807171c3f06d8951da1bf23c5f51961c274bbrbowen <code>else</code> or <code>endif</code> element is included in the
88f586e767b7b224bdb1a178455668a2475cfc75rbowen output stream.</p>
88f586e767b7b224bdb1a178455668a2475cfc75rbowen <p>The <code>elif</code> or <code>else</code> statements are used
88f586e767b7b224bdb1a178455668a2475cfc75rbowen to put text into the output stream if the original
88f586e767b7b224bdb1a178455668a2475cfc75rbowen <var>test_condition</var> was false. These elements are optional.</p>
88f586e767b7b224bdb1a178455668a2475cfc75rbowen <p>The <code>endif</code> element ends the <code>if</code> element
88f586e767b7b224bdb1a178455668a2475cfc75rbowen and is required.</p>
88f586e767b7b224bdb1a178455668a2475cfc75rbowen <p><var>test_condition</var> is one of the following:</p>
88f586e767b7b224bdb1a178455668a2475cfc75rbowen <dd><p>true if the URL represented by the string is accessible by
88f586e767b7b224bdb1a178455668a2475cfc75rbowen configuration, false otherwise. This test only has an effect if
9a58dc6a2b26ec128b1270cf48810e705f1a90dbsf <directive>SSIAccessEnable</directive> is on. This is useful
88f586e767b7b224bdb1a178455668a2475cfc75rbowen where content on a page is to be hidden from users who are not
88f586e767b7b224bdb1a178455668a2475cfc75rbowen authorized to view the URL, such as a link to that URL. Note
88f586e767b7b224bdb1a178455668a2475cfc75rbowen that the URL is only tested for whether access would be granted,
88f586e767b7b224bdb1a178455668a2475cfc75rbowen not whether the URL exists.</p>
88f586e767b7b224bdb1a178455668a2475cfc75rbowen <!--#if expr="-A /private" --><br />
88f586e767b7b224bdb1a178455668a2475cfc75rbowen Click <a href="/private">here</a> to access private
88f586e767b7b224bdb1a178455668a2475cfc75rbowen information.<br />
88f586e767b7b224bdb1a178455668a2475cfc75rbowen <!--#endif -->
88f586e767b7b224bdb1a178455668a2475cfc75rbowen <dd><p>Compare <var>string1</var> with <var>string2</var>. If
88f586e767b7b224bdb1a178455668a2475cfc75rbowen <var>string2</var> has the form <code>/<var>string2</var>/</code>
88f586e767b7b224bdb1a178455668a2475cfc75rbowen then it is treated as a regular expression. Regular expressions are
88f586e767b7b224bdb1a178455668a2475cfc75rbowen implemented by the <a href="http://www.pcre.org">PCRE</a> engine and
88f586e767b7b224bdb1a178455668a2475cfc75rbowen have the same syntax as those in <a href="http://www.perl.com">perl
88f586e767b7b224bdb1a178455668a2475cfc75rbowen 5</a>. Note that <code>==</code> is just an alias for <code>=</code>
88f586e767b7b224bdb1a178455668a2475cfc75rbowen and behaves exactly the same way.</p>
88f586e767b7b224bdb1a178455668a2475cfc75rbowen <p>If you are matching positive (<code>=</code> or <code>==</code>), you
88f586e767b7b224bdb1a178455668a2475cfc75rbowen can capture grouped parts of the regular expression. The captured parts
88f586e767b7b224bdb1a178455668a2475cfc75rbowen are stored in the special variables <code>$1</code> ..
06ba4a61654b3763ad65f52283832ebf058fdf1cslive <code>$9</code>. The whole string matched by the regular expression is
97a9a944b5887e91042b019776c41d5dd74557aferikabele stored in the special variable <code>$0</code></p>
06ba4a61654b3763ad65f52283832ebf058fdf1cslive <!--#if expr="$QUERY_STRING = /^sid=([a-zA-Z0-9]+)/" --><br />
97a9a944b5887e91042b019776c41d5dd74557aferikabele <!--#set var="session" value="$1" --><br />
bf380c59be3f235bde21f1c00098e09e3cf7e7aerpluem <!--#endif -->
bf380c59be3f235bde21f1c00098e09e3cf7e7aerpluem <dt><code><var>string1</var> < <var>string2</var><br />
bf380c59be3f235bde21f1c00098e09e3cf7e7aerpluem <var>string1</var> >= <var>string2</var></code></dt>
06ba4a61654b3763ad65f52283832ebf058fdf1cslive <dd>Compare <var>string1</var> with <var>string2</var>. Note, that
3b1807171c3f06d8951da1bf23c5f51961c274bbrbowen <code>strcmp(3)</code>). Therefore the string "100" is less than
bf380c59be3f235bde21f1c00098e09e3cf7e7aerpluem <p>"<code>=</code>" and "<code>!=</code>" bind more tightly than
97a9a944b5887e91042b019776c41d5dd74557aferikabele "<code>&&</code>" and "<code>||</code>". "<code>!</code>" binds
bf380c59be3f235bde21f1c00098e09e3cf7e7aerpluem most tightly. Thus, the following are equivalent:</p>
81785f72c9d133aef57ad6b02f248345d90239aapoirier <!--#if expr="$a = test1 && $b = test2" --><br />
bf380c59be3f235bde21f1c00098e09e3cf7e7aerpluem <!--#if expr="($a = test1) && ($b = test2)" -->
3b1807171c3f06d8951da1bf23c5f51961c274bbrbowen <p>The boolean operators <code>&&</code> and <code>||</code>
3b1807171c3f06d8951da1bf23c5f51961c274bbrbowen share the same priority. So if you want to bind such an operator more
3b1807171c3f06d8951da1bf23c5f51961c274bbrbowen tightly, you should use parentheses.</p>
3b1807171c3f06d8951da1bf23c5f51961c274bbrbowen <p>Anything that's not recognized as a variable or an operator
3b1807171c3f06d8951da1bf23c5f51961c274bbrbowen is treated as a string. Strings can also be quoted:
06ba4a61654b3763ad65f52283832ebf058fdf1cslive <code>'string'</code>. Unquoted strings can't contain whitespace
06ba4a61654b3763ad65f52283832ebf058fdf1cslive (blanks and tabs) because it is used to separate tokens such as
bf380c59be3f235bde21f1c00098e09e3cf7e7aerpluem variables. If multiple strings are found in a row, they are
06ba4a61654b3763ad65f52283832ebf058fdf1cslive concatenated using blanks. So,</p>
97a9a944b5887e91042b019776c41d5dd74557aferikabele <p><code><var>string1</var> <var
06ba4a61654b3763ad65f52283832ebf058fdf1cslive >string2</var></code> results in <code><var>string1</var> <var
fa1092e17f0b85a610379ac564334ad879ed7dbarbowen >string1</var> <var>string2</var></code>.</p>
fa1092e17f0b85a610379ac564334ad879ed7dbarbowen <note><title>Optimization of Boolean Expressions</title>
fa1092e17f0b85a610379ac564334ad879ed7dbarbowen <p>If the expressions become more complex and slow down processing
fa1092e17f0b85a610379ac564334ad879ed7dbarbowen significantly, you can try to optimize them according to the
17ade6df5ec233536985eb1c130a906c725dd614humbedooh evaluation rules:</p>
fa1092e17f0b85a610379ac564334ad879ed7dbarbowen <li>Expressions are evaluated from left to right</li>
17ade6df5ec233536985eb1c130a906c725dd614humbedooh <li>Binary boolean operators (<code>&&</code> and <code>||</code>)
17ade6df5ec233536985eb1c130a906c725dd614humbedooh are short circuited wherever possible. In conclusion with the rule
4cb65c31bc681540ea623e1cb2bdd09749fb8d7esf above that means, <module>mod_include</module> evaluates at first
4cb65c31bc681540ea623e1cb2bdd09749fb8d7esf the left expression. If the left result is sufficient to determine
5ae30adbe59946de742ab0cd6be3b7457471a698takashi the end result, processing stops here. Otherwise it evaluates the
bf380c59be3f235bde21f1c00098e09e3cf7e7aerpluem right side and computes the end result from both left and right
06ba4a61654b3763ad65f52283832ebf058fdf1cslive results.</li>
bf380c59be3f235bde21f1c00098e09e3cf7e7aerpluem <li>Short circuit evaluation is turned off as long as there are regular
bf380c59be3f235bde21f1c00098e09e3cf7e7aerpluem expressions to deal with. These must be evaluated to fill in the
22d5d84393d960a2027f472036f3fee15d7dbce9nd backreference variables (<code>$1</code> .. <code>$9</code>).</li>
06ba4a61654b3763ad65f52283832ebf058fdf1cslive <p>If you want to look how a particular expression is handled, you can
97a9a944b5887e91042b019776c41d5dd74557aferikabele <code>-DDEBUG_INCLUDE</code> compiler option. This inserts for every
81785f72c9d133aef57ad6b02f248345d90239aapoirier parsed expression tokenizer information, the parse tree and how it is
5ae30adbe59946de742ab0cd6be3b7457471a698takashi evaluated into the output sent to the client.</p>
06ba4a61654b3763ad65f52283832ebf058fdf1cslive <note><title>Escaping slashes in regex strings</title>
06ba4a61654b3763ad65f52283832ebf058fdf1cslive <p>All slashes which are not intended to act as delimiters in your regex must
06ba4a61654b3763ad65f52283832ebf058fdf1cslive be escaped. This is regardless of their meaning to the regex engine.</p>
bf380c59be3f235bde21f1c00098e09e3cf7e7aerpluem<directivesynopsis>
06ba4a61654b3763ad65f52283832ebf058fdf1cslive<description>String that ends an include element</description>
025069f3f8c6b59e730a72c229329dfad5a28424rbowen<contextlist><context>server config</context><context>virtual host</context>
025069f3f8c6b59e730a72c229329dfad5a28424rbowen</contextlist>
06ba4a61654b3763ad65f52283832ebf058fdf1cslive<compatibility>Available in version 2.0.30 and later.</compatibility>
06ba4a61654b3763ad65f52283832ebf058fdf1cslive <p>This directive changes the string that <module>mod_include</module>
bf380c59be3f235bde21f1c00098e09e3cf7e7aerpluem looks for to mark the end of an include element.</p>
9335f6d807d76d60e54af4ededdebebddb3e3d13noodl SSIEndTag "%>"
9335f6d807d76d60e54af4ededdebebddb3e3d13noodl<seealso><directive module="mod_include">SSIStartTag</directive></seealso>
9335f6d807d76d60e54af4ededdebebddb3e3d13noodl</directivesynopsis>
9335f6d807d76d60e54af4ededdebebddb3e3d13noodl<directivesynopsis>
9335f6d807d76d60e54af4ededdebebddb3e3d13noodl<description>String displayed when an unset variable is echoed</description>
bf380c59be3f235bde21f1c00098e09e3cf7e7aerpluem<contextlist><context>server config</context><context>virtual host</context>
06ba4a61654b3763ad65f52283832ebf058fdf1cslive<context>directory</context><context>.htaccess</context></contextlist>
06ba4a61654b3763ad65f52283832ebf058fdf1cslive<compatibility>Available in version 2.0.34 and later.</compatibility>
06ba4a61654b3763ad65f52283832ebf058fdf1cslive <p>This directive changes the string that <module>mod_include</module>
06ba4a61654b3763ad65f52283832ebf058fdf1cslive displays when a variable is not set and "echoed".</p>
06ba4a61654b3763ad65f52283832ebf058fdf1cslive SSIUndefinedEcho "<!-- undef -->"
06ba4a61654b3763ad65f52283832ebf058fdf1cslive</directivesynopsis>
06ba4a61654b3763ad65f52283832ebf058fdf1cslive<directivesynopsis>
17ade6df5ec233536985eb1c130a906c725dd614humbedooh<description>Error message displayed when there is an SSI
06ba4a61654b3763ad65f52283832ebf058fdf1csliveerror</description>
5ae30adbe59946de742ab0cd6be3b7457471a698takashi<default>SSIErrorMsg "[an error occurred while processing this
bf380c59be3f235bde21f1c00098e09e3cf7e7aerpluemdirective]"</default>
5ae30adbe59946de742ab0cd6be3b7457471a698takashi<contextlist><context>server config</context><context>virtual host</context>
bf380c59be3f235bde21f1c00098e09e3cf7e7aerpluem<context>directory</context><context>.htaccess</context></contextlist>
5ae30adbe59946de742ab0cd6be3b7457471a698takashi<compatibility>Available in version 2.0.30 and later.</compatibility>
bf380c59be3f235bde21f1c00098e09e3cf7e7aerpluem <p>The <directive>SSIErrorMsg</directive> directive changes the error
06ba4a61654b3763ad65f52283832ebf058fdf1cslive message displayed when <module>mod_include</module> encounters an
0c4abc32c00611fe1d52c9661f5cc79a3f74c6d4nd error. For production servers you may consider changing the default
0c4abc32c00611fe1d52c9661f5cc79a3f74c6d4nd error message to <code>"<!-- Error -->"</code> so that
0c4abc32c00611fe1d52c9661f5cc79a3f74c6d4nd the message is not presented to the user.</p>
0c4abc32c00611fe1d52c9661f5cc79a3f74c6d4nd <p>This directive has the same effect as the <code><!--#config
0c4abc32c00611fe1d52c9661f5cc79a3f74c6d4nd SSIErrorMsg "<!-- Error -->"
0c4abc32c00611fe1d52c9661f5cc79a3f74c6d4nd </example>
0c4abc32c00611fe1d52c9661f5cc79a3f74c6d4nd</directivesynopsis>
06ba4a61654b3763ad65f52283832ebf058fdf1cslive<directivesynopsis>
06ba4a61654b3763ad65f52283832ebf058fdf1cslive<description>String that starts an include element</description>
06ba4a61654b3763ad65f52283832ebf058fdf1cslive<contextlist><context>server config</context><context>virtual host</context>
06ba4a61654b3763ad65f52283832ebf058fdf1cslive</contextlist>
06ba4a61654b3763ad65f52283832ebf058fdf1cslive<compatibility>Available in version 2.0.30 and later.</compatibility>
4c36c711036219c80d5517d35be68a4769c15291slive <p>This directive changes the string that <module>mod_include</module>
4c36c711036219c80d5517d35be68a4769c15291slive looks for to mark an include element to process.</p>
4c36c711036219c80d5517d35be68a4769c15291slive <p>You may want to use this option if you have 2 servers parsing the
0c4abc32c00611fe1d52c9661f5cc79a3f74c6d4nd output of a file each processing different commands (possibly at
fc9f416faa11879811f17d6efadedbf81cfd52a1covener different times).</p>
fc9f416faa11879811f17d6efadedbf81cfd52a1covener SSIStartTag "<%"<br />
fc9f416faa11879811f17d6efadedbf81cfd52a1covener SSIEndTag "%>"
0c4abc32c00611fe1d52c9661f5cc79a3f74c6d4nd </example>
0c4abc32c00611fe1d52c9661f5cc79a3f74c6d4nd <p>The example given above, which also specifies a matching
0c4abc32c00611fe1d52c9661f5cc79a3f74c6d4nd <directive module="mod_include">SSIEndTag</directive>, will
0c4abc32c00611fe1d52c9661f5cc79a3f74c6d4nd allow you to use SSI directives as shown in the example
0c4abc32c00611fe1d52c9661f5cc79a3f74c6d4nd below:</p>
0c4abc32c00611fe1d52c9661f5cc79a3f74c6d4nd <example><title>SSI directives with alternate start and end tags</title>
0c4abc32c00611fe1d52c9661f5cc79a3f74c6d4nd <%printenv %>
0c4abc32c00611fe1d52c9661f5cc79a3f74c6d4nd </example>
cea021a7fc2657b091df4d3b031c4254ec371dd7rbowen<seealso><directive module="mod_include">SSIEndTag</directive></seealso>
0c4abc32c00611fe1d52c9661f5cc79a3f74c6d4nd</directivesynopsis>
06ba4a61654b3763ad65f52283832ebf058fdf1cslive<directivesynopsis>
06ba4a61654b3763ad65f52283832ebf058fdf1cslive<description>Configures the format in which date strings are
06ba4a61654b3763ad65f52283832ebf058fdf1cslivedisplayed</description>
06ba4a61654b3763ad65f52283832ebf058fdf1cslive<default>SSITimeFormat "%A, %d-%b-%Y %H:%M:%S %Z"</default>
06ba4a61654b3763ad65f52283832ebf058fdf1cslive<contextlist>
06ba4a61654b3763ad65f52283832ebf058fdf1cslive<context>server config</context><context>virtual host</context>
06ba4a61654b3763ad65f52283832ebf058fdf1cslive<context>directory</context><context>.htaccess</context></contextlist>
97a9a944b5887e91042b019776c41d5dd74557aferikabele<compatibility>Available in version 2.0.30 and later.</compatibility>
06ba4a61654b3763ad65f52283832ebf058fdf1cslive<p>This directive changes the format in which date strings are displayed
06ba4a61654b3763ad65f52283832ebf058fdf1cslive when echoing <code>DATE</code> environment variables. The
06ba4a61654b3763ad65f52283832ebf058fdf1cslive <var>formatstring</var> is as in <code>strftime(3)</code> from the
97a9a944b5887e91042b019776c41d5dd74557aferikabele C standard library.</p>
bf380c59be3f235bde21f1c00098e09e3cf7e7aerpluem <p>This directive has the same effect as the <code><!--#config
06ba4a61654b3763ad65f52283832ebf058fdf1cslive timefmt=<var>formatstring</var> --></code> element.</p>
06ba4a61654b3763ad65f52283832ebf058fdf1cslive SSITimeFormat "%R, %B %d, %Y"
7992de7f9e82ab86effe3dcc5279fb959f6c398dcovener <p>The above directive would cause times to be displayed in the
06ba4a61654b3763ad65f52283832ebf058fdf1cslive format "22:26, June 14, 2002".</p>
0ccb6ee166750359937ae35d59c0beb54f8fd228rbowen</directivesynopsis>
17ade6df5ec233536985eb1c130a906c725dd614humbedooh<directivesynopsis>
17ade6df5ec233536985eb1c130a906c725dd614humbedooh<description>Enable the -A flag during conditional flow control processing.</description>
0ccb6ee166750359937ae35d59c0beb54f8fd228rbowen<contextlist><context>directory</context><context>.htaccess</context></contextlist>
17ade6df5ec233536985eb1c130a906c725dd614humbedooh <p>The <directive>SSIAccessEnable</directive> directive controls whether
8ac3ff7008df949c096f9cd8f769c7893594f61fnd the -A test is enabled during conditional flow control processing.
17ade6df5ec233536985eb1c130a906c725dd614humbedooh <directive>SSIAccessEnable</directive> can take on the following values:</p>
06ba4a61654b3763ad65f52283832ebf058fdf1cslive <dd><!--#if expr="-A /foo"--> will be interpreted as a series
790a477f6ce41161c4173c1e5080a1f569976a1erbowen of string and regular expression tokens, the -A has no special
790a477f6ce41161c4173c1e5080a1f569976a1erbowen meaning.</dd>
790a477f6ce41161c4173c1e5080a1f569976a1erbowen <dd><!--#if expr="-A /foo"--> will evaluate to false if the
790a477f6ce41161c4173c1e5080a1f569976a1erbowen URL /foo is inaccessible by configuration, or true otherwise.</dd>
790a477f6ce41161c4173c1e5080a1f569976a1erbowen</directivesynopsis>
9a58dc6a2b26ec128b1270cf48810e705f1a90dbsf<directivesynopsis>
0a3142725875ea286597e083547d34d98f8c1f2drbowen<description>Parse SSI directives in files with the execute bit
790a477f6ce41161c4173c1e5080a1f569976a1erbowenset</description>
e3248eba424ca31b252fbc567032d10082fefd01covener<contextlist><context>server config</context><context>virtual host</context>
790a477f6ce41161c4173c1e5080a1f569976a1erbowen<context>directory</context><context>.htaccess</context></contextlist>
790a477f6ce41161c4173c1e5080a1f569976a1erbowen <p>The <directive>XBitHack</directive> directive controls the parsing
790a477f6ce41161c4173c1e5080a1f569976a1erbowen of ordinary html documents. This directive only affects files associated
790a477f6ce41161c4173c1e5080a1f569976a1erbowen with the <glossary>MIME-type</glossary> <code>text/html</code>. <directive
790a477f6ce41161c4173c1e5080a1f569976a1erbowen >XBitHack</directive> can take on the following values:</p>
0c4abc32c00611fe1d52c9661f5cc79a3f74c6d4nd <dd>Any <code>text/html</code> file that has the user-execute bit
0c4abc32c00611fe1d52c9661f5cc79a3f74c6d4nd set will be treated as a server-parsed html document.</dd>
0203b896e484dfb877111aceffb812401d0f216and <dd>As for <code>on</code> but also test the group-execute bit.
0c4abc32c00611fe1d52c9661f5cc79a3f74c6d4nd If it is set, then set the <code>Last-modified</code> date of the
0c4abc32c00611fe1d52c9661f5cc79a3f74c6d4nd returned file to be the last modified time of the file. If
0c4abc32c00611fe1d52c9661f5cc79a3f74c6d4nd it is not set, then no last-modified date is sent. Setting
0c4abc32c00611fe1d52c9661f5cc79a3f74c6d4nd this bit allows clients and proxies to cache the result of
844def494f17cb1ab0983427d5c3939e1a03ff8cnd the request.
06ba4a61654b3763ad65f52283832ebf058fdf1cslive <p>You would not want to use the full option, unless you assure the
06ba4a61654b3763ad65f52283832ebf058fdf1cslive group-execute bit is unset for every SSI script which might <code
06ba4a61654b3763ad65f52283832ebf058fdf1cslive >#include</code> a CGI or otherwise produces different output on
81785f72c9d133aef57ad6b02f248345d90239aapoirier each hit (or could potentially change on subsequent requests).</p>
9a58dc6a2b26ec128b1270cf48810e705f1a90dbsf</directivesynopsis>
bf380c59be3f235bde21f1c00098e09e3cf7e7aerpluem</modulesynopsis>