1<?xml version="1.0" encoding="ISO-8859-1"?> 2<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd"> 3<html xmlns="http://www.w3.org/1999/xhtml" lang="en" xml:lang="en"><head><!-- 4 XXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX 5 This file is generated from xml source: DO NOT EDIT 6 XXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX 7 --> 8<title>mod_include - Apache HTTP Server</title> 9<link href="/style/css/manual.css" rel="stylesheet" media="all" type="text/css" title="Main stylesheet" /> 10<link href="/style/css/manual-loose-100pc.css" rel="alternate stylesheet" media="all" type="text/css" title="No Sidebar - Default font size" /> 11<link href="/style/css/manual-print.css" rel="stylesheet" media="print" type="text/css" /><link rel="stylesheet" type="text/css" href="/style/css/prettify.css" /> 12<script src="/style/scripts/prettify.js" type="text/javascript"> 13</script> 14 15<link href="/images/favicon.ico" rel="shortcut icon" /></head> 16<body> 17<div id="page-header"> 18<p class="menu"><a href="/mod/">Modules</a> | <a href="/mod/directives.html">Directives</a> | <a href="http://wiki.apache.org/httpd/FAQ">FAQ</a> | <a href="/glossary.html">Glossary</a> | <a href="/sitemap.html">Sitemap</a></p> 19<p class="apache">Apache HTTP Server Version 2.2</p> 20<img alt="" src="/images/feather.gif" /></div> 21<div class="up"><a href="./"><img title="<-" alt="<-" src="/images/left.gif" /></a></div> 22<div id="path"> 23<a href="http://www.apache.org/">Apache</a> > <a href="http://httpd.apache.org/">HTTP Server</a> > <a href="http://httpd.apache.org/docs/">Documentation</a> > <a href="../">Version 2.2</a> > <a href="./">Modules</a></div> 24<div id="page-content"> 25<div id="preamble"><h1>Apache Module mod_include</h1> 26<div class="toplang"> 27<p><span>Available Languages: </span><a href="/en/mod/mod_include.html" title="English"> en </a> | 28<a href="/ja/mod/mod_include.html" hreflang="ja" rel="alternate" title="Japanese"> ja </a></p> 29</div> 30<table class="module"><tr><th><a href="module-dict.html#Description">Description:</a></th><td>Server-parsed html documents (Server Side Includes)</td></tr> 31<tr><th><a href="module-dict.html#Status">Status:</a></th><td>Base</td></tr> 32<tr><th><a href="module-dict.html#ModuleIdentifier">Module�Identifier:</a></th><td>include_module</td></tr> 33<tr><th><a href="module-dict.html#SourceFile">Source�File:</a></th><td>mod_include.c</td></tr> 34<tr><th><a href="module-dict.html#Compatibility">Compatibility:</a></th><td>Implemented as an output filter since Apache 352.0</td></tr></table> 36<h3>Summary</h3> 37 38 <p>This module provides a filter which will process files 39 before they are sent to the client. The processing is 40 controlled by specially formatted SGML comments, referred to as 41 <dfn>elements</dfn>. These elements allow conditional text, the 42 inclusion of other files or programs, as well as the setting and 43 printing of environment variables.</p> 44</div> 45<div id="quickview"><h3 class="directives">Directives</h3> 46<ul id="toc"> 47<li><img alt="" src="/images/down.gif" /> <a href="#ssienableaccess">SSIEnableAccess</a></li> 48<li><img alt="" src="/images/down.gif" /> <a href="#ssiendtag">SSIEndTag</a></li> 49<li><img alt="" src="/images/down.gif" /> <a href="#ssierrormsg">SSIErrorMsg</a></li> 50<li><img alt="" src="/images/down.gif" /> <a href="#ssietag">SSIETag</a></li> 51<li><img alt="" src="/images/down.gif" /> <a href="#ssilastmodified">SSILastModified</a></li> 52<li><img alt="" src="/images/down.gif" /> <a href="#ssistarttag">SSIStartTag</a></li> 53<li><img alt="" src="/images/down.gif" /> <a href="#ssitimeformat">SSITimeFormat</a></li> 54<li><img alt="" src="/images/down.gif" /> <a href="#ssiundefinedecho">SSIUndefinedEcho</a></li> 55<li><img alt="" src="/images/down.gif" /> <a href="#xbithack">XBitHack</a></li> 56</ul> 57<h3>Topics</h3> 58<ul id="topics"> 59<li><img alt="" src="/images/down.gif" /> <a href="#enabling">Enabling Server-Side Includes</a></li> 60<li><img alt="" src="/images/down.gif" /> <a href="#pathinfo">PATH_INFO with Server Side Includes</a></li> 61<li><img alt="" src="/images/down.gif" /> <a href="#elements">Basic Elements</a></li> 62<li><img alt="" src="/images/down.gif" /> <a href="#includevars">Include Variables</a></li> 63<li><img alt="" src="/images/down.gif" /> <a href="#substitution">Variable Substitution</a></li> 64<li><img alt="" src="/images/down.gif" /> <a href="#flowctrl">Flow Control Elements</a></li> 65</ul><h3>See also</h3> 66<ul class="seealso"> 67<li><code class="directive"><a href="/mod/core.html#options">Options</a></code></li> 68<li><code class="directive"><a href="/mod/core.html#acceptpathinfo">AcceptPathInfo</a></code></li> 69<li><a href="/filter.html">Filters</a></li> 70<li><a href="/howto/ssi.html">SSI Tutorial</a></li> 71</ul><ul class="seealso"><li><a href="#comments_section">Comments</a></li></ul></div> 72<div class="top"><a href="#page-header"><img alt="top" src="/images/up.gif" /></a></div> 73<div class="section"> 74<h2><a name="enabling" id="enabling">Enabling Server-Side Includes</a></h2> 75 76 77 <p>Server Side Includes are implemented by the 78 <code>INCLUDES</code> <a href="/filter.html">filter</a>. If 79 documents containing server-side include directives are given 80 the extension .shtml, the following directives will make Apache 81 parse them and assign the resulting document the mime type of 82 <code>text/html</code>:</p> 83 84 <div class="example"><p><code> 85 AddType text/html .shtml<br /> 86 AddOutputFilter INCLUDES .shtml 87 </code></p></div> 88 89 <p>The following directive must be given for the directories 90 containing the shtml files (typically in a 91 <code class="directive"><a href="/mod/core.html#directory"><Directory></a></code> section, 92 but this directive is also valid in <code>.htaccess</code> files if 93 <code class="directive"><a href="/mod/core.html#allowoverride">AllowOverride</a></code> <code>Options</code> 94 is set):</p> 95 96 <div class="example"><p><code> 97 Options +Includes 98 </code></p></div> 99 100 <p>For backwards compatibility, the <code>server-parsed</code> 101 <a href="/handler.html">handler</a> also activates the 102 INCLUDES filter. As well, Apache will activate the INCLUDES 103 filter for any document with mime type 104 <code>text/x-server-parsed-html</code> or 105 <code>text/x-server-parsed-html3</code> (and the resulting 106 output will have the mime type <code>text/html</code>).</p> 107 108 <p>For more information, see our <a href="/howto/ssi.html">Tutorial on Server Side Includes</a>.</p> 109</div><div class="top"><a href="#page-header"><img alt="top" src="/images/up.gif" /></a></div> 110<div class="section"> 111<h2><a name="pathinfo" id="pathinfo">PATH_INFO with Server Side Includes</a></h2> 112 113 114 <p>Files processed for server-side includes no longer accept 115 requests with <code>PATH_INFO</code> (trailing pathname information) 116 by default. You can use the <code class="directive"><a href="/mod/core.html#acceptpathinfo">AcceptPathInfo</a></code> directive to 117 configure the server to accept requests with <code>PATH_INFO</code>.</p> 118</div><div class="top"><a href="#page-header"><img alt="top" src="/images/up.gif" /></a></div> 119<div class="section"> 120<h2><a name="elements" id="elements">Basic Elements</a></h2> 121 <p>The document is parsed as an HTML document, with special 122 commands embedded as SGML comments. A command has the syntax: </p> 123 124 <div class="example"><p><code> 125 <!--#<var>element</var> <var>attribute</var>=<var>value</var> 126 <var>attribute</var>=<var>value</var> ... --> 127 </code></p></div> 128 129 <p>The value will often be enclosed in double quotes, but single 130 quotes (<code>'</code>) and backticks (<code>`</code>) are also 131 possible. Many commands only allow a single attribute-value pair. 132 Note that the comment terminator (<code>--></code>) should be 133 preceded by whitespace to ensure that it isn't considered part of 134 an SSI token. Note that the leading <code><!--#</code> is <em>one</em> 135 token and may not contain any whitespaces.</p> 136 137 <p>The allowed elements are listed in the following table:</p> 138 139 <table class="bordered"> 140 <tr><th>Element</th><th>Description</th></tr> 141 <tr><td><code><a href="#element.config">config</a></code></td> 142 <td>configure output formats</td></tr> 143 <tr><td><code><a href="#element.echo">echo</a></code></td> 144 <td>print variables</td></tr> 145 <tr><td><code><a href="#element.exec">exec</a></code></td> 146 <td>execute external programs</td></tr> 147 <tr><td><code><a href="#element.fsize">fsize</a></code></td> 148 <td>print size of a file</td></tr> 149 <tr><td><code><a href="#element.flastmod">flastmod</a></code></td> 150 <td>print last modification time of a file</td></tr> 151 <tr><td><code><a href="#element.include">include</a></code></td> 152 <td>include a file</td></tr> 153 <tr><td><code><a href="#element.printenv">printenv</a></code></td> 154 <td>print all available variables</td></tr> 155 <tr><td><code><a href="#element.set">set</a></code></td> 156 <td>set a value of a variable</td></tr> 157 </table> 158 159 <p>SSI elements may be defined by modules other than 160 <code class="module"><a href="/mod/mod_include.html">mod_include</a></code>. In fact, the <code><a href="#element.exec">exec</a></code> element is provided by 161 <code class="module"><a href="/mod/mod_cgi.html">mod_cgi</a></code>, and will only be available if this 162 module is loaded.</p> 163 164 <h3><a name="element.config" id="element.config">The config Element</a></h3> 165 <p>This command controls various aspects of the parsing. The 166 valid attributes are:</p> 167 168 <dl> 169 <dt><code>echomsg</code> (<em>Apache 2.1 and later</em>)</dt> 170 <dd>The value is a message that is sent back to the 171 client if the <code><a href="#element.echo">echo</a></code> element 172 attempts to echo an undefined variable. This overrides any <code class="directive"><a href="#ssiundefinedecho">SSIUndefinedEcho</a></code> directives.</dd> 173 174 <dt><code>errmsg</code></dt> 175 <dd>The value is a message that is sent back to the 176 client if an error occurs while parsing the 177 document. This overrides any <code class="directive"><a href="#ssierrormsg">SSIErrorMsg</a></code> directives.</dd> 178 179 <dt><code>sizefmt</code></dt> 180 <dd>The value sets the format to be used when displaying 181 the size of a file. Valid values are <code>bytes</code> 182 for a count in bytes, or <code>abbrev</code> for a count 183 in Kb or Mb as appropriate, for example a size of 1024 bytes 184 will be printed as "1K".</dd> 185 186 <dt><code>timefmt</code></dt> 187 <dd>The value is a string to be used by the 188 <code>strftime(3)</code> library routine when printing 189 dates.</dd> 190 </dl> 191 192 193 <h3><a name="element.echo" id="element.echo">The echo Element</a></h3> 194 <p>This command prints one of the <a href="#includevars">include 195 variables</a> defined below. If the variable is unset, the result is 196 determined by the <code class="directive"><a href="#ssiundefinedecho">SSIUndefinedEcho</a></code> directive. Any dates printed are 197 subject to the currently configured <code>timefmt</code>.</p> 198 199 <p>Attributes:</p> 200 201 <dl> 202 <dt><code>var</code></dt> 203 <dd>The value is the name of the variable to print.</dd> 204 205 <dt><code>encoding</code></dt> 206 <dd><p>Specifies how Apache should encode special characters 207 contained in the variable before outputting them. If set 208 to <code>none</code>, no encoding will be done. If set to 209 <code>url</code>, then URL encoding (also known as %-encoding; 210 this is appropriate for use within URLs in links, etc.) will be 211 performed. At the start of an <code>echo</code> element, 212 the default is set to <code>entity</code>, resulting in entity 213 encoding (which is appropriate in the context of a block-level 214 HTML element, <em>e.g.</em> a paragraph of text). This can be 215 changed by adding an <code>encoding</code> attribute, which will 216 remain in effect until the next <code>encoding</code> attribute 217 is encountered or the element ends, whichever comes first.</p> 218 219 <p>The <code>encoding</code> attribute must <em>precede</em> the 220 corresponding <code>var</code> attribute to be effective, and 221 only special characters as defined in the ISO-8859-1 character 222 encoding will be encoded. This encoding process may not have the 223 desired result if a different character encoding is in use.</p> 224 225 <div class="warning"> 226 In order to avoid cross-site scripting issues, you should 227 <em>always</em> encode user supplied data. 228 </div> 229 </dd> 230 </dl> 231 232 233 <h3><a name="element.exec" id="element.exec">The exec Element</a></h3> 234 <p>The <code>exec</code> command executes a given shell command or 235 CGI script. It requires <code class="module"><a href="/mod/mod_cgi.html">mod_cgi</a></code> to be present 236 in the server. If <code class="directive"><a href="/mod/core.html#options">Options</a></code> 237 <code>IncludesNOEXEC</code> is set, this command is completely 238 disabled. The valid attributes are:</p> 239 240 <dl> 241 <dt><code>cgi</code></dt> 242 <dd><p>The value specifies a (%-encoded) URL-path to 243 the CGI script. If the path does not begin with a slash (/), 244 then it is taken to be relative to the current 245 document. The document referenced by this path is 246 invoked as a CGI script, even if the server would not 247 normally recognize it as such. However, the directory 248 containing the script must be enabled for CGI scripts 249 (with <code class="directive"><a href="/mod/mod_alias.html#scriptalias">ScriptAlias</a></code> 250 or <code class="directive"><a href="/mod/core.html#options">Options</a></code> 251 <code>ExecCGI</code>).</p> 252 253 <p>The CGI script is given the <code>PATH_INFO</code> and query 254 string (<code>QUERY_STRING</code>) of the original request from the 255 client; these <em>cannot</em> be specified in the URL path. The 256 include variables will be available to the script in addition to 257 the standard <a href="mod_cgi.html">CGI</a> environment.</p> 258 259 <div class="example"><h3>Example</h3><p><code> 260 <!--#exec cgi="/cgi-bin/example.cgi" --> 261 </code></p></div> 262 263 <p>If the script returns a <code>Location:</code> header instead of 264 output, then this will be translated into an HTML anchor.</p> 265 266 <p>The <code><a href="#includevirtual">include virtual</a></code> 267 element should be used in preference to <code>exec cgi</code>. In 268 particular, if you need to pass additional arguments to a CGI program, 269 using the query string, this cannot be done with <code>exec 270 cgi</code>, but can be done with <code>include virtual</code>, as 271 shown here:</p> 272 273 <div class="example"><p><code> 274 <!--#include virtual="/cgi-bin/example.cgi?argument=value" --> 275 </code></p></div> 276 </dd> 277 278 <dt><code>cmd</code></dt> 279 <dd><p>The server will execute the given string using 280 <code>/bin/sh</code>. The <a href="#includevars">include variables</a> are available to the command, in addition 281 to the usual set of CGI variables.</p> 282 283 <p>The use of <code><a href="#includevirtual">#include virtual</a></code> is almost always prefered to using 284 either <code>#exec cgi</code> or <code>#exec cmd</code>. The former 285 (<code>#include virtual</code>) uses the standard Apache sub-request 286 mechanism to include files or scripts. It is much better tested and 287 maintained.</p> 288 289 <p>In addition, on some platforms, like Win32, and on unix when 290 using <a href="/suexec.html">suexec</a>, you cannot pass arguments 291 to a command in an <code>exec</code> directive, or otherwise include 292 spaces in the command. Thus, while the following will work under a 293 non-suexec configuration on unix, it will not produce the desired 294 result under Win32, or when running suexec:</p> 295 296 <div class="example"><p><code> 297 <!--#exec cmd="perl /path/to/perlscript arg1 arg2" --> 298 </code></p></div> 299 </dd> 300 </dl> 301 302 303 <h3><a name="element.fsize" id="element.fsize">The fsize Element</a></h3> 304 <p>This command prints the size of the specified file, subject 305 to the <code>sizefmt</code> format specification. Attributes:</p> 306 307 <dl> 308 <dt><code>file</code></dt> 309 <dd>The value is a path relative to the directory 310 containing the current document being parsed.</dd> 311 312 <dt><code>virtual</code></dt> 313 <dd>The value is a (%-encoded) URL-path. If it does not begin with 314 a slash (/) then it is taken to be relative to the current document. 315 Note, that this does <em>not</em> print the size of any CGI output, 316 but the size of the CGI script itself.</dd> 317 </dl> 318 319 320 <h3><a name="element.flastmod" id="element.flastmod">The flastmod Element</a></h3> 321 <p>This command prints the last modification date of the 322 specified file, subject to the <code>timefmt</code> format 323 specification. The attributes are the same as for the 324 <code><a href="#element.fsize">fsize</a></code> command.</p> 325 326 327 <h3><a name="element.include" id="element.include">The include Element</a></h3> 328 <p>This command inserts the text of another document or file 329 into the parsed file. Any included file is subject to the usual 330 access control. If the directory containing the parsed file has 331 <a href="core.html#options">Options</a> 332 <code>IncludesNOEXEC</code> set, then only documents with a text 333 <a class="glossarylink" href="/glossary.html#mime-type" title="see glossary">MIME-type</a> (<code>text/plain</code>, 334 <code>text/html</code> etc.) will be included. Otherwise CGI 335 scripts are invoked as normal using the complete URL given in 336 the command, including any query string.</p> 337 338 <p>An attribute defines the location of the document; the 339 inclusion is done for each attribute given to the include 340 command. The valid attributes are:</p> 341 342 <dl> 343 <dt><code>file</code></dt> 344 <dd>The value is a path relative to the directory 345 containing the current document being parsed. It cannot 346 contain <code>../</code>, nor can it be an absolute path. 347 Therefore, you cannot include files that are outside of the 348 document root, or above the current document in the directory 349 structure. The <code>virtual</code> attribute should always be 350 used in preference to this one.</dd> 351 352 <dt><code><a id="includevirtual" name="includevirtual">virtual</a></code></dt> 353 <dd><p>The value is a (%-encoded) URL-path. The URL cannot contain a 354 scheme or hostname, only a path and an optional query string. If it 355 does not begin with a slash (/) then it is taken to be relative to the 356 current document.</p> 357 358 <p>A URL is constructed from the attribute, and the output the 359 server would return if the URL were accessed by the client is 360 included in the parsed output. Thus included files can be nested.</p> 361 362 <p>If the specified URL is a CGI program, the program will be 363 executed and its output inserted in place of the directive in the 364 parsed file. You may include a query string in a CGI url:</p> 365 366 <div class="example"><p><code> 367 <!--#include virtual="/cgi-bin/example.cgi?argument=value" --> 368 </code></p></div> 369 370 <p><code>include virtual</code> should be used in preference 371 to <code>exec cgi</code> to include the output of CGI programs 372 into an HTML document.</p> 373 </dd> 374 </dl> 375 376 377 <h3><a name="element.printenv" id="element.printenv">The printenv Element</a></h3> 378 <p>This prints out a listing of all existing variables and 379 their values. Special characters are entity encoded (see the <code><a href="#element.echo">echo</a></code> element for details) 380 before being output. There are no attributes.</p> 381 382 <div class="example"><h3>Example</h3><p><code> 383 <!--#printenv --> 384 </code></p></div> 385 386 387 <h3><a name="element.set" id="element.set">The set Element</a></h3> 388 <p>This sets the value of a variable. Attributes:</p> 389 390 <dl> 391 <dt><code>var</code></dt> 392 <dd>The name of the variable to set.</dd> 393 394 <dt><code>value</code></dt> 395 <dd>The value to give a variable.</dd> 396 </dl> 397 398 <div class="example"><h3>Example</h3><p><code> 399 <!--#set var="category" value="help" --> 400 </code></p></div> 401 402</div><div class="top"><a href="#page-header"><img alt="top" src="/images/up.gif" /></a></div> 403<div class="section"> 404<h2><a name="includevars" id="includevars">Include Variables</a></h2> 405 406 407 <p>In addition to the variables in the standard CGI environment, 408 these are available for the <code>echo</code> command, for 409 <code>if</code> and <code>elif</code>, and to any program 410 invoked by the document.</p> 411 412 <dl> 413 <dt><code>DATE_GMT</code></dt> 414 <dd>The current date in Greenwich Mean Time.</dd> 415 416 <dt><code>DATE_LOCAL</code></dt> 417 <dd>The current date in the local time zone.</dd> 418 419 <dt><code>DOCUMENT_NAME</code></dt> 420 <dd>The filename (excluding directories) of the document 421 requested by the user.</dd> 422 423 <dt><code>DOCUMENT_URI</code></dt> 424 <dd>The (%-decoded) URL path of the document requested by the 425 user. Note that in the case of nested include files, this is 426 <em>not</em> the URL for the current document. Note also that 427 if the URL is modified internally (e.g. by an <code class="directive"><a href="/mod/mod_alias.html#alias">alias</a></code> or <code class="directive"><a href="/mod/mod_dir.html#directoryindex">directoryindex</a></code>), the modified 428 URL is shown.</dd> 429 430 <dt><code>LAST_MODIFIED</code></dt> 431 <dd>The last modification date of the document requested by 432 the user.</dd> 433 434 <dt><code>QUERY_STRING_UNESCAPED</code></dt> 435 <dd>If a query string is present, this variable contains the 436 (%-decoded) query string, which is <em>escaped</em> for shell 437 usage (special characters like <code>&</code> etc. are 438 preceded by backslashes).</dd> 439 </dl> 440</div><div class="top"><a href="#page-header"><img alt="top" src="/images/up.gif" /></a></div> 441<div class="section"> 442<h2><a name="substitution" id="substitution">Variable Substitution</a></h2> 443 444 <p>Variable substitution is done within quoted strings in most 445 cases where they may reasonably occur as an argument to an SSI 446 directive. This includes the <code>config</code>, 447 <code>exec</code>, <code>flastmod</code>, <code>fsize</code>, 448 <code>include</code>, <code>echo</code>, and <code>set</code> 449 directives, as well as the arguments to conditional operators. 450 You can insert a literal dollar sign into the string using backslash 451 quoting:</p> 452 453 <div class="example"><p><code> 454 <!--#if expr="$a = \$test" --> 455 </code></p></div> 456 457 <p>If a variable reference needs to be substituted in the 458 middle of a character sequence that might otherwise be 459 considered a valid identifier in its own right, it can be 460 disambiguated by enclosing the reference in braces, 461 <em>a la</em> shell substitution:</p> 462 463 <div class="example"><p><code> 464 <!--#set var="Zed" value="${REMOTE_HOST}_${REQUEST_METHOD}" --> 465 </code></p></div> 466 467 <p>This will result in the <code>Zed</code> variable being set 468 to "<code>X_Y</code>" if <code>REMOTE_HOST</code> is 469 "<code>X</code>" and <code>REQUEST_METHOD</code> is 470 "<code>Y</code>".</p> 471 472 <p>The below example will print "in foo" if the 473 <code>DOCUMENT_URI</code> is <code>/foo/file.html</code>, "in bar" 474 if it is <code>/bar/file.html</code> and "in neither" otherwise:</p> 475 476 <div class="example"><p><code> 477 <!--#if expr='"$DOCUMENT_URI" = "/foo/file.html"' --><br /> 478 <span class="indent"> 479 in foo<br /> 480 </span> 481 <!--#elif expr='"$DOCUMENT_URI" = "/bar/file.html"' --><br /> 482 <span class="indent"> 483 in bar<br /> 484 </span> 485 <!--#else --><br /> 486 <span class="indent"> 487 in neither<br /> 488 </span> 489 <!--#endif --> 490 </code></p></div> 491</div><div class="top"><a href="#page-header"><img alt="top" src="/images/up.gif" /></a></div> 492<div class="section"> 493<h2><a name="flowctrl" id="flowctrl">Flow Control Elements</a></h2> 494 495 496 <p>The basic flow control elements are:</p> 497 498 <div class="example"><p><code> 499 <!--#if expr="<var>test_condition</var>" --><br /> 500 <!--#elif expr="<var>test_condition</var>" --><br /> 501 <!--#else --><br /> 502 <!--#endif --> 503 </code></p></div> 504 505 <p>The <code>if</code> element works like an if statement in a 506 programming language. The test condition is evaluated and if 507 the result is true, then the text until the next <code>elif</code>, 508 <code>else</code> or <code>endif</code> element is included in the 509 output stream.</p> 510 511 <p>The <code>elif</code> or <code>else</code> statements are used 512 to put text into the output stream if the original 513 <var>test_condition</var> was false. These elements are optional.</p> 514 515 <p>The <code>endif</code> element ends the <code>if</code> element 516 and is required.</p> 517 518 <p><var>test_condition</var> is one of the following:</p> 519 520 <dl> 521 <dt><code><var>string</var></code></dt> 522 <dd>true if <var>string</var> is not empty</dd> 523 524 <dt><code><var>-A string</var></code></dt> 525 <dd><p>true if the URL represented by the string is accessible by 526 configuration, false otherwise. This test only has an effect if 527 <code class="directive">SSIEnableAccess</code> is on. This is useful 528 where content on a page is to be hidden from users who are not 529 authorized to view the URL, such as a link to that URL. Note 530 that the URL is only tested for whether access would be granted, 531 not whether the URL exists.</p> 532 533 <div class="example"><h3>Example</h3><p><code> 534 <!--#if expr="-A /private" --><br /> 535 <span class="indent"> 536 Click <a href="/private">here</a> to access private 537 information.<br /> 538 </span> 539 <!--#endif --> 540 </code></p></div> 541 </dd> 542 543 <dt><code><var>string1</var> = <var>string2</var><br /> 544 <var>string1</var> == <var>string2</var><br /> 545 <var>string1</var> != <var>string2</var></code></dt> 546 547 <dd><p>Compare <var>string1</var> with <var>string2</var>. If 548 <var>string2</var> has the form <code>/<var>string2</var>/</code> 549 then it is treated as a regular expression. Regular expressions are 550 implemented by the <a href="http://www.pcre.org">PCRE</a> engine and 551 have the same syntax as those in <a href="http://www.perl.com">perl 552 5</a>. Note that <code>==</code> is just an alias for <code>=</code> 553 and behaves exactly the same way.</p> 554 555 <p>If you are matching positive (<code>=</code> or <code>==</code>), you 556 can capture grouped parts of the regular expression. The captured parts 557 are stored in the special variables <code>$1</code> .. 558 <code>$9</code>.</p> 559 560 <div class="example"><h3>Example</h3><p><code> 561 <!--#if expr="$QUERY_STRING = /^sid=([a-zA-Z0-9]+)/" --><br /> 562 <span class="indent"> 563 <!--#set var="session" value="$1" --><br /> 564 </span> 565 <!--#endif --> 566 </code></p></div> 567 </dd> 568 569 <dt><code><var>string1</var> < <var>string2</var><br /> 570 <var>string1</var> <= <var>string2</var><br /> 571 <var>string1</var> > <var>string2</var><br /> 572 <var>string1</var> >= <var>string2</var></code></dt> 573 574 <dd>Compare <var>string1</var> with <var>string2</var>. Note, that 575 strings are compared <em>literally</em> (using 576 <code>strcmp(3)</code>). Therefore the string "100" is less than 577 "20".</dd> 578 579 <dt><code>( <var>test_condition</var> )</code></dt> 580 <dd>true if <var>test_condition</var> is true</dd> 581 582 <dt><code>! <var>test_condition</var></code></dt> 583 <dd>true if <var>test_condition</var> is false</dd> 584 585 <dt><code><var>test_condition1</var> && 586 <var>test_condition2</var></code></dt> 587 <dd>true if both <var>test_condition1</var> and 588 <var>test_condition2</var> are true</dd> 589 590 <dt><code><var>test_condition1</var> || 591 <var>test_condition2</var></code></dt> 592 <dd>true if either <var>test_condition1</var> or 593 <var>test_condition2</var> is true</dd> 594 </dl> 595 596 <p>"<code>=</code>" and "<code>!=</code>" bind more tightly than 597 "<code>&&</code>" and "<code>||</code>". "<code>!</code>" binds 598 most tightly. Thus, the following are equivalent:</p> 599 600 <div class="example"><p><code> 601 <!--#if expr="$a = test1 && $b = test2" --><br /> 602 <!--#if expr="($a = test1) && ($b = test2)" --> 603 </code></p></div> 604 605 <p>The boolean operators <code>&&</code> and <code>||</code> 606 share the same priority. So if you want to bind such an operator more 607 tightly, you should use parentheses.</p> 608 609 <p>Anything that's not recognized as a variable or an operator 610 is treated as a string. Strings can also be quoted: 611 <code>'string'</code>. Unquoted strings can't contain whitespace 612 (blanks and tabs) because it is used to separate tokens such as 613 variables. If multiple strings are found in a row, they are 614 concatenated using blanks. So,</p> 615 616 <div class="example"><p><code><var>string1</var> <var>string2</var></code> results in <code><var>string1</var> <var>string2</var></code><br /> 617 <br /> 618 and<br /> 619 <br /> 620 <code>'<var>string1</var> <var>string2</var>'</code> results in <code><var>string1</var> <var>string2</var></code>.</p></div> 621 622 <div class="note"><h3>Optimization of Boolean Expressions</h3> 623 <p>If the expressions become more complex and slow down processing 624 significantly, you can try to optimize them according to the 625 evaluation rules:</p> 626 <ul> 627 <li>Expressions are evaluated from left to right</li> 628 <li>Binary boolean operators (<code>&&</code> and <code>||</code>) 629 are short circuited wherever possible. In conclusion with the rule 630 above that means, <code class="module"><a href="/mod/mod_include.html">mod_include</a></code> evaluates at first 631 the left expression. If the left result is sufficient to determine 632 the end result, processing stops here. Otherwise it evaluates the 633 right side and computes the end result from both left and right 634 results.</li> 635 <li>Short circuit evaluation is turned off as long as there are regular 636 expressions to deal with. These must be evaluated to fill in the 637 backreference variables (<code>$1</code> .. <code>$9</code>).</li> 638 </ul> 639 <p>If you want to look how a particular expression is handled, you can 640 recompile <code class="module"><a href="/mod/mod_include.html">mod_include</a></code> using the 641 <code>-DDEBUG_INCLUDE</code> compiler option. This inserts for every 642 parsed expression tokenizer information, the parse tree and how it is 643 evaluated into the output sent to the client.</p> 644 </div> 645 646 <div class="note"><h3>Escaping slashes in regex strings</h3> 647 <p>All slashes which are not intended to act as delimiters in your regex must 648 be escaped. This is regardless of their meaning to the regex engine.</p> 649 </div> 650</div> 651<div class="top"><a href="#page-header"><img alt="top" src="/images/up.gif" /></a></div> 652<div class="directive-section"><h2><a name="SSIEnableAccess" id="SSIEnableAccess">SSIEnableAccess</a> <a name="ssienableaccess" id="ssienableaccess">Directive</a></h2> 653<table class="directive"> 654<tr><th><a href="directive-dict.html#Description">Description:</a></th><td>Enable the -A flag during conditional flow control processing.</td></tr> 655<tr><th><a href="directive-dict.html#Syntax">Syntax:</a></th><td><code>SSIEnableAccess on|off</code></td></tr> 656<tr><th><a href="directive-dict.html#Default">Default:</a></th><td><code>SSIEnableAccess off</code></td></tr> 657<tr><th><a href="directive-dict.html#Context">Context:</a></th><td>directory, .htaccess</td></tr> 658<tr><th><a href="directive-dict.html#Status">Status:</a></th><td>Base</td></tr> 659<tr><th><a href="directive-dict.html#Module">Module:</a></th><td>mod_include</td></tr> 660</table> 661 <p>The <code class="directive">SSIEnableAccess</code> directive controls whether 662 the -A test is enabled during conditional flow control processing. 663 <code class="directive">SSIEnableAccess</code> can take on the following values:</p> 664 665 <dl> 666 667 <dt><code>off</code></dt> 668 <dd><!--#if expr="-A /foo"--> will be interpreted as a series 669 of string and regular expression tokens, the -A has no special 670 meaning.</dd> 671 672 <dt><code>on</code></dt> 673 <dd><!--#if expr="-A /foo"--> will evaluate to false if the 674 URL /foo is inaccessible by configuration, or true otherwise.</dd> 675 676 </dl> 677 678 679</div> 680<div class="top"><a href="#page-header"><img alt="top" src="/images/up.gif" /></a></div> 681<div class="directive-section"><h2><a name="SSIEndTag" id="SSIEndTag">SSIEndTag</a> <a name="ssiendtag" id="ssiendtag">Directive</a></h2> 682<table class="directive"> 683<tr><th><a href="directive-dict.html#Description">Description:</a></th><td>String that ends an include element</td></tr> 684<tr><th><a href="directive-dict.html#Syntax">Syntax:</a></th><td><code>SSIEndTag <var>tag</var></code></td></tr> 685<tr><th><a href="directive-dict.html#Default">Default:</a></th><td><code>SSIEndTag "-->"</code></td></tr> 686<tr><th><a href="directive-dict.html#Context">Context:</a></th><td>server config, virtual host</td></tr> 687<tr><th><a href="directive-dict.html#Status">Status:</a></th><td>Base</td></tr> 688<tr><th><a href="directive-dict.html#Module">Module:</a></th><td>mod_include</td></tr> 689<tr><th><a href="directive-dict.html#Compatibility">Compatibility:</a></th><td>Available in version 2.0.30 and later.</td></tr> 690</table> 691 <p>This directive changes the string that <code class="module"><a href="/mod/mod_include.html">mod_include</a></code> 692 looks for to mark the end of an include element.</p> 693 694 <div class="example"><h3>Example</h3><p><code> 695 SSIEndTag "%>" 696 </code></p></div> 697 698 699<h3>See also</h3> 700<ul> 701<li><code class="directive"><a href="#ssistarttag">SSIStartTag</a></code></li> 702</ul> 703</div> 704<div class="top"><a href="#page-header"><img alt="top" src="/images/up.gif" /></a></div> 705<div class="directive-section"><h2><a name="SSIErrorMsg" id="SSIErrorMsg">SSIErrorMsg</a> <a name="ssierrormsg" id="ssierrormsg">Directive</a></h2> 706<table class="directive"> 707<tr><th><a href="directive-dict.html#Description">Description:</a></th><td>Error message displayed when there is an SSI 708error</td></tr> 709<tr><th><a href="directive-dict.html#Syntax">Syntax:</a></th><td><code>SSIErrorMsg <var>message</var></code></td></tr> 710<tr><th><a href="directive-dict.html#Default">Default:</a></th><td><code>SSIErrorMsg "[an error occurred while processing this 711directive]"</code></td></tr> 712<tr><th><a href="directive-dict.html#Context">Context:</a></th><td>server config, virtual host, directory, .htaccess</td></tr> 713<tr><th><a href="directive-dict.html#Override">Override:</a></th><td>All</td></tr> 714<tr><th><a href="directive-dict.html#Status">Status:</a></th><td>Base</td></tr> 715<tr><th><a href="directive-dict.html#Module">Module:</a></th><td>mod_include</td></tr> 716<tr><th><a href="directive-dict.html#Compatibility">Compatibility:</a></th><td>Available in version 2.0.30 and later.</td></tr> 717</table> 718 <p>The <code class="directive">SSIErrorMsg</code> directive changes the error 719 message displayed when <code class="module"><a href="/mod/mod_include.html">mod_include</a></code> encounters an 720 error. For production servers you may consider changing the default 721 error message to <code>"<!-- Error -->"</code> so that 722 the message is not presented to the user.</p> 723 724 <p>This directive has the same effect as the <code><!--#config 725 errmsg=<var>message</var> --></code> element.</p> 726 727 <div class="example"><h3>Example</h3><p><code> 728 SSIErrorMsg "<!-- Error -->" 729 </code></p></div> 730 731</div> 732<div class="top"><a href="#page-header"><img alt="top" src="/images/up.gif" /></a></div> 733<div class="directive-section"><h2><a name="SSIETag" id="SSIETag">SSIETag</a> <a name="ssietag" id="ssietag">Directive</a></h2> 734<table class="directive"> 735<tr><th><a href="directive-dict.html#Description">Description:</a></th><td>Controls whether ETags are generated by the server.</td></tr> 736<tr><th><a href="directive-dict.html#Syntax">Syntax:</a></th><td><code>SSIETag on|off</code></td></tr> 737<tr><th><a href="directive-dict.html#Default">Default:</a></th><td><code>SSIETag off</code></td></tr> 738<tr><th><a href="directive-dict.html#Context">Context:</a></th><td>directory, .htaccess</td></tr> 739<tr><th><a href="directive-dict.html#Status">Status:</a></th><td>Base</td></tr> 740<tr><th><a href="directive-dict.html#Module">Module:</a></th><td>mod_include</td></tr> 741<tr><th><a href="directive-dict.html#Compatibility">Compatibility:</a></th><td>Available in version 2.2.15 and later.</td></tr> 742</table> 743 <p>Under normal circumstances, a file filtered by <code class="module"><a href="/mod/mod_include.html">mod_include</a></code> 744 may contain elements that are either dynamically generated, or that may 745 have changed independently of the original file. As a result, by default 746 the server is asked not to generate an <code>ETag</code> header for the 747 response by adding <code>no-etag</code> to the request notes.</p> 748 749 <p>The <code class="directive">SSIETag</code> directive suppresses this 750 behaviour, and allows the server to generate an <code>ETag</code> header. 751 This can be used to enable caching of the output. Note that a backend server 752 or dynamic content generator may generate an ETag of its own, ignoring 753 <code>no-etag</code>, and this ETag will be passed by 754 <code class="module"><a href="/mod/mod_include.html">mod_include</a></code> regardless of the value of this setting. 755 <code class="directive">SSIETag</code> can take on the following values:</p> 756 757 <dl> 758 759 <dt><code>off</code></dt> 760 <dd><code>no-etag</code> will be added to the request notes, and the server 761 is asked not to generate an ETag. Where a server ignores the value of 762 <code>no-etag</code> and generates an ETag anyway, the ETag will be 763 respected.</dd> 764 765 <dt><code>on</code></dt> 766 <dd>Existing ETags will be respected, and ETags generated by the server will 767 be passed on in the response.</dd> 768 769 </dl> 770 771 772</div> 773<div class="top"><a href="#page-header"><img alt="top" src="/images/up.gif" /></a></div> 774<div class="directive-section"><h2><a name="SSILastModified" id="SSILastModified">SSILastModified</a> <a name="ssilastmodified" id="ssilastmodified">Directive</a></h2> 775<table class="directive"> 776<tr><th><a href="directive-dict.html#Description">Description:</a></th><td>Controls whether <code>Last-Modified</code> headers are generated by the 777server.</td></tr> 778<tr><th><a href="directive-dict.html#Syntax">Syntax:</a></th><td><code>SSILastModified on|off</code></td></tr> 779<tr><th><a href="directive-dict.html#Default">Default:</a></th><td><code>SSILastModified off</code></td></tr> 780<tr><th><a href="directive-dict.html#Context">Context:</a></th><td>directory, .htaccess</td></tr> 781<tr><th><a href="directive-dict.html#Status">Status:</a></th><td>Base</td></tr> 782<tr><th><a href="directive-dict.html#Module">Module:</a></th><td>mod_include</td></tr> 783<tr><th><a href="directive-dict.html#Compatibility">Compatibility:</a></th><td>Available in version 2.2.15 and later.</td></tr> 784</table> 785 <p>Under normal circumstances, a file filtered by <code class="module"><a href="/mod/mod_include.html">mod_include</a></code> 786 may contain elements that are either dynamically generated, or that may 787 have changed independently of the original file. As a result, by default 788 the <code>Last-Modified</code> header is stripped from the response.</p> 789 790 <p>The <code class="directive">SSILastModified</code> directive overrides this 791 behaviour, and allows the <code>Last-Modified</code> header to be respected 792 if already present, or set if the header is not already present. This can 793 be used to enable caching of the output. <code class="directive">SSILastModified</code> 794 can take on the following values:</p> 795 796 <dl> 797 798 <dt><code>off</code></dt> 799 <dd>The <code>Last-Modified</code> header will be stripped from responses, 800 unless the <code class="directive"><a href="#xbithack">XBitHack</a></code> directive 801 is set to <code>full</code> as described below.</dd> 802 803 <dt><code>on</code></dt> 804 <dd>The <code>Last-Modified</code> header will be respected if already 805 present in a response, and added to the response if the response is a 806 file and the header is missing. The 807 <code class="directive"><a href="#ssilastmodified">SSILastModified</a></code> directive 808 takes precedence over <code class="directive"><a href="#xbithack">XBitHack</a></code>.</dd> 809 810 </dl> 811 812 813</div> 814<div class="top"><a href="#page-header"><img alt="top" src="/images/up.gif" /></a></div> 815<div class="directive-section"><h2><a name="SSIStartTag" id="SSIStartTag">SSIStartTag</a> <a name="ssistarttag" id="ssistarttag">Directive</a></h2> 816<table class="directive"> 817<tr><th><a href="directive-dict.html#Description">Description:</a></th><td>String that starts an include element</td></tr> 818<tr><th><a href="directive-dict.html#Syntax">Syntax:</a></th><td><code>SSIStartTag <var>tag</var></code></td></tr> 819<tr><th><a href="directive-dict.html#Default">Default:</a></th><td><code>SSIStartTag "<!--#"</code></td></tr> 820<tr><th><a href="directive-dict.html#Context">Context:</a></th><td>server config, virtual host</td></tr> 821<tr><th><a href="directive-dict.html#Status">Status:</a></th><td>Base</td></tr> 822<tr><th><a href="directive-dict.html#Module">Module:</a></th><td>mod_include</td></tr> 823<tr><th><a href="directive-dict.html#Compatibility">Compatibility:</a></th><td>Available in version 2.0.30 and later.</td></tr> 824</table> 825 <p>This directive changes the string that <code class="module"><a href="/mod/mod_include.html">mod_include</a></code> 826 looks for to mark an include element to process.</p> 827 828 <p>You may want to use this option if you have 2 servers parsing the 829 output of a file each processing different commands (possibly at 830 different times).</p> 831 832 <div class="example"><h3>Example</h3><p><code> 833 SSIStartTag "<%"<br /> 834 SSIEndTag "%>" 835 </code></p></div> 836 837 <p>The example given above, which also specifies a matching 838 <code class="directive"><a href="#ssiendtag">SSIEndTag</a></code>, will 839 allow you to use SSI directives as shown in the example 840 below:</p> 841 842 <div class="example"><h3>SSI directives with alternate start and end tags</h3><p><code> 843 <%printenv %> 844 </code></p></div> 845 846<h3>See also</h3> 847<ul> 848<li><code class="directive"><a href="#ssiendtag">SSIEndTag</a></code></li> 849</ul> 850</div> 851<div class="top"><a href="#page-header"><img alt="top" src="/images/up.gif" /></a></div> 852<div class="directive-section"><h2><a name="SSITimeFormat" id="SSITimeFormat">SSITimeFormat</a> <a name="ssitimeformat" id="ssitimeformat">Directive</a></h2> 853<table class="directive"> 854<tr><th><a href="directive-dict.html#Description">Description:</a></th><td>Configures the format in which date strings are 855displayed</td></tr> 856<tr><th><a href="directive-dict.html#Syntax">Syntax:</a></th><td><code>SSITimeFormat <var>formatstring</var></code></td></tr> 857<tr><th><a href="directive-dict.html#Default">Default:</a></th><td><code>SSITimeFormat "%A, %d-%b-%Y %H:%M:%S %Z"</code></td></tr> 858<tr><th><a href="directive-dict.html#Context">Context:</a></th><td>server config, virtual host, directory, .htaccess</td></tr> 859<tr><th><a href="directive-dict.html#Override">Override:</a></th><td>All</td></tr> 860<tr><th><a href="directive-dict.html#Status">Status:</a></th><td>Base</td></tr> 861<tr><th><a href="directive-dict.html#Module">Module:</a></th><td>mod_include</td></tr> 862<tr><th><a href="directive-dict.html#Compatibility">Compatibility:</a></th><td>Available in version 2.0.30 and later.</td></tr> 863</table> 864<p>This directive changes the format in which date strings are displayed 865 when echoing <code>DATE</code> environment variables. The 866 <var>formatstring</var> is as in <code>strftime(3)</code> from the 867 C standard library.</p> 868 869 <p>This directive has the same effect as the <code><!--#config 870 timefmt=<var>formatstring</var> --></code> element.</p> 871 872 <div class="example"><h3>Example</h3><p><code> 873 SSITimeFormat "%R, %B %d, %Y" 874 </code></p></div> 875 876 <p>The above directive would cause times to be displayed in the 877 format "22:26, June 14, 2002".</p> 878 879</div> 880<div class="top"><a href="#page-header"><img alt="top" src="/images/up.gif" /></a></div> 881<div class="directive-section"><h2><a name="SSIUndefinedEcho" id="SSIUndefinedEcho">SSIUndefinedEcho</a> <a name="ssiundefinedecho" id="ssiundefinedecho">Directive</a></h2> 882<table class="directive"> 883<tr><th><a href="directive-dict.html#Description">Description:</a></th><td>String displayed when an unset variable is echoed</td></tr> 884<tr><th><a href="directive-dict.html#Syntax">Syntax:</a></th><td><code>SSIUndefinedEcho <var>string</var></code></td></tr> 885<tr><th><a href="directive-dict.html#Default">Default:</a></th><td><code>SSIUndefinedEcho "(none)"</code></td></tr> 886<tr><th><a href="directive-dict.html#Context">Context:</a></th><td>server config, virtual host, directory, .htaccess</td></tr> 887<tr><th><a href="directive-dict.html#Override">Override:</a></th><td>All</td></tr> 888<tr><th><a href="directive-dict.html#Status">Status:</a></th><td>Base</td></tr> 889<tr><th><a href="directive-dict.html#Module">Module:</a></th><td>mod_include</td></tr> 890<tr><th><a href="directive-dict.html#Compatibility">Compatibility:</a></th><td>Available in version 2.0.34 and later.</td></tr> 891</table> 892 <p>This directive changes the string that <code class="module"><a href="/mod/mod_include.html">mod_include</a></code> 893 displays when a variable is not set and "echoed".</p> 894 895 <div class="example"><h3>Example</h3><p><code> 896 SSIUndefinedEcho "<!-- undef -->" 897 </code></p></div> 898 899</div> 900<div class="top"><a href="#page-header"><img alt="top" src="/images/up.gif" /></a></div> 901<div class="directive-section"><h2><a name="XBitHack" id="XBitHack">XBitHack</a> <a name="xbithack" id="xbithack">Directive</a></h2> 902<table class="directive"> 903<tr><th><a href="directive-dict.html#Description">Description:</a></th><td>Parse SSI directives in files with the execute bit 904set</td></tr> 905<tr><th><a href="directive-dict.html#Syntax">Syntax:</a></th><td><code>XBitHack on|off|full</code></td></tr> 906<tr><th><a href="directive-dict.html#Default">Default:</a></th><td><code>XBitHack off</code></td></tr> 907<tr><th><a href="directive-dict.html#Context">Context:</a></th><td>server config, virtual host, directory, .htaccess</td></tr> 908<tr><th><a href="directive-dict.html#Override">Override:</a></th><td>Options</td></tr> 909<tr><th><a href="directive-dict.html#Status">Status:</a></th><td>Base</td></tr> 910<tr><th><a href="directive-dict.html#Module">Module:</a></th><td>mod_include</td></tr> 911</table> 912 <p>The <code class="directive">XBitHack</code> directive controls the parsing 913 of ordinary html documents. This directive only affects files associated 914 with the <a class="glossarylink" href="/glossary.html#mime-type" title="see glossary">MIME-type</a> <code>text/html</code>. <code class="directive">XBitHack</code> can take on the following values:</p> 915 916 <dl> 917 <dt><code>off</code></dt> 918 <dd>No special treatment of executable files.</dd> 919 920 <dt><code>on</code></dt> 921 <dd>Any <code>text/html</code> file that has the user-execute bit 922 set will be treated as a server-parsed html document.</dd> 923 924 <dt><code>full</code></dt> 925 <dd>As for <code>on</code> but also test the group-execute bit. 926 If it is set, then set the <code>Last-modified</code> date of the 927 returned file to be the last modified time of the file. If 928 it is not set, then no last-modified date is sent. Setting 929 this bit allows clients and proxies to cache the result of 930 the request. 931 932 <div class="note"><h3>Note</h3> 933 <p>You would not want to use the full option, unless you assure the 934 group-execute bit is unset for every SSI script which might <code>#include</code> a CGI or otherwise produces different output on 935 each hit (or could potentially change on subsequent requests).</p> 936 937 <p>The <code class="directive"><a href="#ssilastmodified">SSILastModified</a></code> 938 directive takes precedence over the 939 <code class="directive"><a href="#xbithack">XBitHack</a></code> directive when 940 <code class="directive"><a href="#ssilastmodified">SSILastModified</a></code> is set to 941 <code>on</code>.</p> 942 </div> 943 944 </dd> 945 </dl> 946 947 948</div> 949</div> 950<div class="bottomlang"> 951<p><span>Available Languages: </span><a href="/en/mod/mod_include.html" title="English"> en </a> | 952<a href="/ja/mod/mod_include.html" hreflang="ja" rel="alternate" title="Japanese"> ja </a></p> 953</div><div class="top"><a href="#page-header"><img src="/images/up.gif" alt="top" /></a></div><div class="section"><h2><a id="comments_section" name="comments_section">Comments</a></h2><div class="warning"><strong>Notice:</strong><br />This is not a Q&A section. Comments placed here should be pointed towards suggestions on improving the documentation or server, and may be removed again by our moderators if they are either implemented or considered invalid/off-topic. Questions on how to manage the Apache HTTP Server should be directed at either our IRC channel, #httpd, on Freenode, or sent to our <a href="http://httpd.apache.org/lists.html">mailing lists</a>.</div> 954<script type="text/javascript"><!--//--><![CDATA[//><!-- 955var comments_shortname = 'httpd'; 956var comments_identifier = 'http://httpd.apache.org/docs/2.2/mod/mod_include.html'; 957(function(w, d) { 958 if (w.location.hostname.toLowerCase() == "httpd.apache.org") { 959 d.write('<div id="comments_thread"><\/div>'); 960 var s = d.createElement('script'); 961 s.type = 'text/javascript'; 962 s.async = true; 963 s.src = 'https://comments.apache.org/show_comments.lua?site=' + comments_shortname + '&page=' + comments_identifier; 964 (d.getElementsByTagName('head')[0] || d.getElementsByTagName('body')[0]).appendChild(s); 965 } 966 else { 967 d.write('<div id="comments_thread">Comments are disabled for this page at the moment.<\/div>'); 968 } 969})(window, document); 970//--><!]]></script></div><div id="footer"> 971<p class="apache">Copyright 2013 The Apache Software Foundation.<br />Licensed under the <a href="http://www.apache.org/licenses/LICENSE-2.0">Apache License, Version 2.0</a>.</p> 972<p class="menu"><a href="/mod/">Modules</a> | <a href="/mod/directives.html">Directives</a> | <a href="http://wiki.apache.org/httpd/FAQ">FAQ</a> | <a href="/glossary.html">Glossary</a> | <a href="/sitemap.html">Sitemap</a></p></div><script type="text/javascript"><!--//--><![CDATA[//><!-- 973if (typeof(prettyPrint) !== 'undefined') { 974 prettyPrint(); 975} 976//--><!]]></script> 977</body></html>