summaryrefslogtreecommitdiff
path: root/docs/manual/env.html.en
diff options
context:
space:
mode:
authorJoshua Slive <slive@apache.org>2002-08-22 02:53:02 +0000
committerJoshua Slive <slive@apache.org>2002-08-22 02:53:02 +0000
commitfaf86a24fdbe86e2b79ef2d6c582cbbe9e816816 (patch)
treec7690ba0bc98ba48e5a2c795acdf90716e776a59 /docs/manual/env.html.en
parentc14aa6528b4ba6cb1e1c151ed336b140325ced58 (diff)
downloadhttpd-faf86a24fdbe86e2b79ef2d6c582cbbe9e816816.tar.gz
Update the environment variable docs with a couple new
special-purpose variables and a reference to the mod_ext_filter use of env variables. git-svn-id: https://svn.apache.org/repos/asf/httpd/httpd/trunk@96481 13f79535-47bb-0310-9956-ffa450edef68
Diffstat (limited to 'docs/manual/env.html.en')
-rw-r--r--docs/manual/env.html.en75
1 files changed, 57 insertions, 18 deletions
diff --git a/docs/manual/env.html.en b/docs/manual/env.html.en
index 34caa7aaaa..1b231c0f3b 100644
--- a/docs/manual/env.html.en
+++ b/docs/manual/env.html.en
@@ -2,7 +2,7 @@
XXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX
This file is generated from xml source: DO NOT EDIT
XXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX
- --><title>Environment Variables in Apache - Apache HTTP Server</title><link href="./style/manual.css" type="text/css" rel="stylesheet"></head><body><blockquote><div align="center"><img src="./images/sub.gif" alt="[APACHE DOCUMENTATION]"><h3>Apache HTTP Server Version 2.0</h3></div><h1 align="center">Environment Variables in Apache</h1>
+ --><title>Environment Variables in Apache - Apache HTTP Server</title><link href="../style/manual.css" type="text/css" rel="stylesheet"></head><body><blockquote><div align="center"><img src="../images/sub.gif" alt="[APACHE DOCUMENTATION]"><h3>Apache HTTP Server Version 2.0</h3></div><h1 align="center">Environment Variables in Apache</h1>
<p>The Apache HTTP Server provides a mechanism for storing
information in named variables that are called <em>environment
variables</em>. This information can be used to control various
@@ -22,17 +22,17 @@
server itself runs, you must use the standard environment
manipulation mechanisms provided by your operating system
shell.</p>
- <ul><li><a href="#setting">Setting Environment Variables</a><ul><li><a href="#basic-manipulation">Basic Environment Manipulation</a></li><li><a href="#conditional">Conditional Per-Request Settings</a></li><li><a href="#unique-identifiers">Unique Identifiers</a></li><li><a href="#standard-cgi">Standard CGI Variables</a></li><li><a href="#caveats">Some Caveats</a></li></ul></li><li><a href="#using">Using Environment Variables</a><ul><li><a href="#cgi-scripts">CGI Scripts</a></li><li><a href="#ssi-pages">SSI Pages</a></li><li><a href="#access-control">Access Control</a></li><li><a href="#logging">Conditional Logging</a></li><li><a href="#response-headers">Conditional Response Headers</a></li><li><a href="#url-rewriting">URL Rewriting</a></li></ul></li><li><a href="#special">Special Purpose Environment Variables</a><ul><li><a href="#downgrade">downgrade-1.0</a></li><li><a href="#force-no-vary">force-no-vary</a></li><li><a href="#force-response">force-response-1.0</a></li><li><a href="#nokeepalive">nokeepalive</a></li><li><a href="#redirect-carefully">redirect-carefully</a></li></ul></li><li><a href="#examples">Examples</a><ul><li><a href="#misbehaving">Changing protocol behavior with misbehaving clients</a></li><li><a href="#no-img-log">Do not log requests for images in the access log</a></li><li><a href="#image-theft">Prevent "Image Theft"</a></li></ul></li></ul><hr><h2><a name="setting">Setting Environment Variables</a></h2>
+ <ul><li><a href="#setting">Setting Environment Variables</a><ul><li><a href="#basic-manipulation">Basic Environment Manipulation</a></li><li><a href="#conditional">Conditional Per-Request Settings</a></li><li><a href="#unique-identifiers">Unique Identifiers</a></li><li><a href="#standard-cgi">Standard CGI Variables</a></li><li><a href="#caveats">Some Caveats</a></li></ul></li><li><a href="#using">Using Environment Variables</a><ul><li><a href="#cgi-scripts">CGI Scripts</a></li><li><a href="#ssi-pages">SSI Pages</a></li><li><a href="#access-control">Access Control</a></li><li><a href="#logging">Conditional Logging</a></li><li><a href="#response-headers">Conditional Response Headers</a></li><li><a href="#external-filter">External Filter Activation</a></li><li><a href="#url-rewriting">URL Rewriting</a></li></ul></li><li><a href="#special">Special Purpose Environment Variables</a><ul><li><a href="#downgrade">downgrade-1.0</a></li><li><a href="#force-no-vary">force-no-vary</a></li><li><a href="#force-response">force-response-1.0</a></li><li><a href="#gzip-only-text/html">gzip-only-text/html</a></li><li><a href="#nokeepalive">nokeepalive</a></li><li><a href="#redirect-carefully">redirect-carefully</a></li><li><a href="#suppress-error-charset">suppress-error-charset</a></li></ul></li><li><a href="#examples">Examples</a><ul><li><a href="#misbehaving">Changing protocol behavior with misbehaving clients</a></li><li><a href="#no-img-log">Do not log requests for images in the access log</a></li><li><a href="#image-theft">Prevent "Image Theft"</a></li></ul></li></ul><hr><h2><a name="setting">Setting Environment Variables</a></h2>
- <table border="1"><tr><td valign="top"><strong>Related Modules</strong><br><br><code><a href="./mod/mod_env.html">mod_env</a></code><br><code><a href="./mod/mod_rewrite.html">mod_rewrite</a></code><br><code><a href="./mod/mod_setenvif.html">mod_setenvif</a></code><br><code><a href="./mod/mod_unique_id.html">mod_unique_id</a></code><br></td><td valign="top"><strong>Related Directives</strong><br><br><a href="./mod/mod_setenvif.html#browsermatch" class="directive"><code class="directive">BrowserMatch</code></a><br><a href="./mod/mod_setenvif.html#browsermatchnocase" class="directive"><code class="directive">BrowserMatchNoCase</code></a><br><a href="./mod/mod_env.html#passenv" class="directive"><code class="directive">PassEnv</code></a><br><a href="./mod/mod_rewrite.html#rewriterule" class="directive"><code class="directive">RewriteRule</code></a><br><a href="./mod/mod_env.html#setenv" class="directive"><code class="directive">SetEnv</code></a><br><a href="./mod/mod_setenvif.html#setenvif" class="directive"><code class="directive">SetEnvIf</code></a><br><a href="./mod/mod_setenvif.html#setenvifnocase" class="directive"><code class="directive">SetEnvIfNoCase</code></a><br><a href="./mod/mod_env.html#unsetenv" class="directive"><code class="directive">UnsetEnv</code></a><br></td></tr></table>
+ <table border="1"><tr><td valign="top"><strong>Related Modules</strong><br><br><code><a href="../mod/mod_env.html">mod_env</a></code><br><code><a href="../mod/mod_rewrite.html">mod_rewrite</a></code><br><code><a href="../mod/mod_setenvif.html">mod_setenvif</a></code><br><code><a href="../mod/mod_unique_id.html">mod_unique_id</a></code><br></td><td valign="top"><strong>Related Directives</strong><br><br><a href="../mod/mod_setenvif.html#browsermatch" class="directive"><code class="directive">BrowserMatch</code></a><br><a href="../mod/mod_setenvif.html#browsermatchnocase" class="directive"><code class="directive">BrowserMatchNoCase</code></a><br><a href="../mod/mod_env.html#passenv" class="directive"><code class="directive">PassEnv</code></a><br><a href="../mod/mod_rewrite.html#rewriterule" class="directive"><code class="directive">RewriteRule</code></a><br><a href="../mod/mod_env.html#setenv" class="directive"><code class="directive">SetEnv</code></a><br><a href="../mod/mod_setenvif.html#setenvif" class="directive"><code class="directive">SetEnvIf</code></a><br><a href="../mod/mod_setenvif.html#setenvifnocase" class="directive"><code class="directive">SetEnvIfNoCase</code></a><br><a href="../mod/mod_env.html#unsetenv" class="directive"><code class="directive">UnsetEnv</code></a><br></td></tr></table>
<h3><a name="basic-manipulation">Basic Environment Manipulation</a></h3>
<p>The most basic way to set an environment variable in Apache
- is using the unconditional <a href="./mod/mod_env.html#setenv" class="directive"><code class="directive">SetEnv</code></a> directive. Variables may also be passed from
+ is using the unconditional <a href="../mod/mod_env.html#setenv" class="directive"><code class="directive">SetEnv</code></a> directive. Variables may also be passed from
the environment of the shell which started the server using the
- <a href="./mod/mod_env.html#passenv" class="directive"><code class="directive">PassEnv</code></a> directive.</p>
+ <a href="../mod/mod_env.html#passenv" class="directive"><code class="directive">PassEnv</code></a> directive.</p>
<h3><a name="conditional">Conditional Per-Request Settings</a></h3>
@@ -44,7 +44,7 @@
requests. For example, a variable could be set only when a
specific browser (User-Agent) is making a request, or only when
a specific Referer [sic] header is found. Even more flexibility
- is available through the mod_rewrite's <a href="./mod/mod_rewrite.html#rewriterule" class="directive"><code class="directive">RewriteRule</code></a> which uses the
+ is available through the mod_rewrite's <a href="../mod/mod_rewrite.html#rewriterule" class="directive"><code class="directive">RewriteRule</code></a> which uses the
<code>[E=...]</code> option to set environment variables.</p>
@@ -92,7 +92,7 @@
<h2><a name="using">Using Environment Variables</a></h2>
- <table border="1"><tr><td valign="top"><strong>Related Modules</strong><br><br><code><a href="./mod/mod_access.html">mod_access</a></code><br><code><a href="./mod/mod_cgi.html">mod_cgi</a></code><br><code><a href="./mod/mod_headers.html">mod_headers</a></code><br><code><a href="./mod/mod_include.html">mod_include</a></code><br><code><a href="./mod/mod_log_config.html">mod_log_config</a></code><br><code><a href="./mod/mod_rewrite.html">mod_rewrite</a></code><br></td><td valign="top"><strong>Related Directives</strong><br><br><a href="./mod/mod_access.html#allow" class="directive"><code class="directive">Allow</code></a><br><a href="./mod/mod_log_config.html#customlog" class="directive"><code class="directive">CustomLog</code></a><br><a href="./mod/mod_access.html#deny" class="directive"><code class="directive">Deny</code></a><br><a href="./mod/mod_headers.html#header" class="directive"><code class="directive">Header</code></a><br><a href="./mod/mod_log_config.html#logformat" class="directive"><code class="directive">LogFormat</code></a><br><a href="./mod/mod_rewrite.html#rewritecond" class="directive"><code class="directive">RewriteCond</code></a><br><a href="./mod/mod_rewrite.html#rewriterule" class="directive"><code class="directive">RewriteRule</code></a><br></td></tr></table>
+ <table border="1"><tr><td valign="top"><strong>Related Modules</strong><br><br><code><a href="../mod/mod_access.html">mod_access</a></code><br><code><a href="../mod/mod_cgi.html">mod_cgi</a></code><br><code><a href="../mod/mod_ext_filter.html">mod_ext_filter</a></code><br><code><a href="../mod/mod_headers.html">mod_headers</a></code><br><code><a href="../mod/mod_include.html">mod_include</a></code><br><code><a href="../mod/mod_log_config.html">mod_log_config</a></code><br><code><a href="../mod/mod_rewrite.html">mod_rewrite</a></code><br></td><td valign="top"><strong>Related Directives</strong><br><br><a href="../mod/mod_access.html#allow" class="directive"><code class="directive">Allow</code></a><br><a href="../mod/mod_log_config.html#customlog" class="directive"><code class="directive">CustomLog</code></a><br><a href="../mod/mod_access.html#deny" class="directive"><code class="directive">Deny</code></a><br><a href="../mod/mod_ext_filter.html#extfilterdefine" class="directive"><code class="directive">ExtFilterDefine</code></a><br><a href="../mod/mod_headers.html#header" class="directive"><code class="directive">Header</code></a><br><a href="../mod/mod_log_config.html#logformat" class="directive"><code class="directive">LogFormat</code></a><br><a href="../mod/mod_rewrite.html#rewritecond" class="directive"><code class="directive">RewriteCond</code></a><br><a href="../mod/mod_rewrite.html#rewriterule" class="directive"><code class="directive">RewriteRule</code></a><br></td></tr></table>
<h3><a name="cgi-scripts">CGI Scripts</a></h3>
@@ -123,7 +123,7 @@
<p>Access to the server can be controlled based on the value of
environment variables using the <code>allow from env=</code>
and <code>deny from env=</code> directives. In combination with
- <a href="./mod/mod_setenvif.html#setenvif" class="directive"><code class="directive">SetEnvIf</code></a>, this
+ <a href="../mod/mod_setenvif.html#setenvif" class="directive"><code class="directive">SetEnvIf</code></a>, this
allows for flexible control of access to the server based on
characteristics of the client. For example, you can use these
directives to deny access to a particular browser (User-Agent).
@@ -134,12 +134,12 @@
<p>Environment variables can be logged in the access log using
- the <a href="./mod/mod_log_config.html#logformat" class="directive"><code class="directive">LogFormat</code></a>
+ the <a href="../mod/mod_log_config.html#logformat" class="directive"><code class="directive">LogFormat</code></a>
option <code>%e</code>. In addition, the decision on whether
or not to log requests can be made based on the status of
environment variables using the conditional form of the
- <a href="./mod/mod_log_config.html#customlog" class="directive"><code class="directive">CustomLog</code></a>
- directive. In combination with <a href="./mod/mod_setenvif.html#setenvif" class="directive"><code class="directive">SetEnvIf</code></a> this allows for flexible control of which
+ <a href="../mod/mod_log_config.html#customlog" class="directive"><code class="directive">CustomLog</code></a>
+ directive. In combination with <a href="../mod/mod_setenvif.html#setenvif" class="directive"><code class="directive">SetEnvIf</code></a> this allows for flexible control of which
requests are logged. For example, you can choose not to log
requests for filenames ending in <code>gif</code>, or you can
choose to only log requests from clients which are outside your
@@ -149,7 +149,7 @@
<h3><a name="response-headers">Conditional Response Headers</a></h3>
- <p>The <a href="./mod/mod_headers.html#header" class="directive"><code class="directive">Header</code></a>
+ <p>The <a href="../mod/mod_headers.html#header" class="directive"><code class="directive">Header</code></a>
directive can use the presence or
absence of an environment variable to determine whether or not
a certain HTTP header will be placed in the response to the
@@ -158,11 +158,21 @@
request from the client.</p>
+
+ <h3><a name="external-filter">External Filter Activation</a></h3>
+
+
+ <p>External filters configured by <code><a href="../mod/mod_ext_filter.html">mod_ext_filter</a></code>
+ using the <a href="../mod/mod_ext_filter.html#extfilterdefine" class="directive"><code class="directive">ExtFilterDefine</code></a> directive can
+ by activated conditional on an environment variable using the
+ <code>disableenv=</code> and <code>enableenv=</code> options.</p>
+
+
<h3><a name="url-rewriting">URL Rewriting</a></h3>
<p>The <code>%{ENV:...}</code> form of <em>TestString</em> in
- the <a href="./mod/mod_rewrite.html#rewritecond" class="directive"><code class="directive">RewriteCond</code></a>
+ the <a href="../mod/mod_rewrite.html#rewritecond" class="directive"><code class="directive">RewriteCond</code></a>
allows mod_rewrite's rewrite
engine to make decisions conditional on environment variables.
Note that the variables accessible in mod_rewrite without the
@@ -177,9 +187,9 @@
mechanisms to modify the way Apache behaves when talking to
particular clients. To make these mechanisms as flexible as
possible, they are invoked by defining environment variables,
- typically with <a href="./mod/mod_setenvif.html#browsermatch" class="directive"><code class="directive">BrowserMatch</code></a>,
- though <a href="./mod/mod_env.html#setenv" class="directive"><code class="directive">SetEnv</code></a> and
- <a href="./mod/mod_env.html#passenv" class="directive"><code class="directive">PassEnv</code></a> could also be used,
+ typically with <a href="../mod/mod_setenvif.html#browsermatch" class="directive"><code class="directive">BrowserMatch</code></a>,
+ though <a href="../mod/mod_env.html#setenv" class="directive"><code class="directive">SetEnv</code></a> and
+ <a href="../mod/mod_env.html#passenv" class="directive"><code class="directive">PassEnv</code></a> could also be used,
for example.</p>
<h3><a name="downgrade">downgrade-1.0</a></h3>
@@ -208,11 +218,19 @@
clients may not behave correctly when given an HTTP/1.1
response, and this can be used to interoperate with them.</p>
+
+ <h3><a name="gzip-only-text/html">gzip-only-text/html</a></h3>
+
+
+ <p>When set to a value of "1", this variable disables the DEFLATE
+ output filter provided by <code><a href="../mod/mod_deflate.html">mod_deflate</a></code> for
+ content-types other than <code>text/html</code>.</p>
+
<h3><a name="nokeepalive">nokeepalive</a></h3>
- <p>This disables <a href="./mod/core.html#keepalive" class="directive"><code class="directive">KeepAlive</code></a> when set.</p>
+ <p>This disables <a href="../mod/core.html#keepalive" class="directive"><code class="directive">KeepAlive</code></a> when set.</p>
<h3><a name="redirect-carefully">redirect-carefully</a></h3>
@@ -226,6 +244,27 @@
methods.</p>
+
+ <h3><a name="suppress-error-charset">suppress-error-charset</a></h3>
+
+
+ <p><em>Available in versions after 2.0.40</em></p>
+
+ <p>When Apache issues a redirect in response to a client request,
+ the response includes some actual text to be displayed in case
+ the client can't (or doesn't) automatically follow the redirection.
+ Apache ordinarily labels this text according to the character set
+ which it uses, which is ISO-8859-1.</p>
+ <p> However, if the redirection is to a page that uses a different
+ character set, some broken browser versions will try to use the
+ character set from the redirection text rather than the actual page.
+ This can result in Greek, for instance, being incorrectly rendered.</p>
+ <p>Setting this environment variable causes Apache to omit the character
+ set for the redirection text, and these broken browsers will then correctly
+ use that of the destination page.</p>
+
+
+
<h2><a name="examples">Examples</a></h2>
@@ -292,4 +331,4 @@ SetEnvIf Referer "^$" local_referal
ApacheToday tutorial " <a href="http://apachetoday.com/news_story.php3?ltsn=2000-06-14-002-01-PS">
Keeping Your Images from Adorning Other Sites</a>".</p>
- <hr></blockquote><h3 align="center">Apache HTTP Server Version 2.0</h3><a href="./"><img src="./images/index.gif" alt="Index"></a><a href="./"><img src="./images/home.gif" alt="Home"></a></body></html> \ No newline at end of file
+ <hr></blockquote><h3 align="center">Apache HTTP Server Version 2.0</h3><a href="./"><img src="../images/index.gif" alt="Index"></a><a href="../"><img src="../images/home.gif" alt="Home"></a></body></html> \ No newline at end of file