summaryrefslogtreecommitdiff
path: root/docs/manual/mod/mod_expires.html
diff options
context:
space:
mode:
authorRich Bowen <rbowen@apache.org>2001-09-22 19:39:26 +0000
committerRich Bowen <rbowen@apache.org>2001-09-22 19:39:26 +0000
commitf88b50dec40878abeccce0e1b9cfc6780a4b1465 (patch)
tree84e6a7b926e102d9f322b96351f2346be29c2db5 /docs/manual/mod/mod_expires.html
parent651abc3a73acadb00f390b58ed4e5b7ebb14d2b0 (diff)
downloadhttpd-f88b50dec40878abeccce0e1b9cfc6780a4b1465.tar.gz
w3c tidy to convert to xhtml
git-svn-id: https://svn.apache.org/repos/asf/httpd/httpd/trunk@91116 13f79535-47bb-0310-9956-ffa450edef68
Diffstat (limited to 'docs/manual/mod/mod_expires.html')
-rw-r--r--docs/manual/mod/mod_expires.html598
1 files changed, 254 insertions, 344 deletions
diff --git a/docs/manual/mod/mod_expires.html b/docs/manual/mod/mod_expires.html
index c80b194ae0..bae83e9873 100644
--- a/docs/manual/mod/mod_expires.html
+++ b/docs/manual/mod/mod_expires.html
@@ -1,350 +1,260 @@
-<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 3.2 Final//EN">
-<HTML>
- <HEAD>
- <TITLE>Apache module mod_expires</TITLE>
- </HEAD>
-<!-- Background white, links blue (unvisited), navy (visited), red (active) -->
- <BODY
- BGCOLOR="#FFFFFF"
- TEXT="#000000"
- LINK="#0000FF"
- VLINK="#000080"
- ALINK="#FF0000"
- >
- <!--#include virtual="header.html" -->
- <H1 ALIGN="CENTER">Module mod_expires</H1>
- <P>
- This module provides for the generation of <CODE>Expires</CODE> HTTP
- headers according to user-specified criteria.
- </P>
-
-<P><A
-HREF="module-dict.html#Status"
-REL="Help"
-><STRONG>Status:</STRONG></A> Extension
-<BR>
-<A
-HREF="module-dict.html#SourceFile"
-REL="Help"
-><STRONG>Source File:</STRONG></A> mod_expires.c
-<BR>
-<A
-HREF="module-dict.html#ModuleIdentifier"
-REL="Help"
-><STRONG>Module Identifier:</STRONG></A> expires_module
-<BR>
-<A
-HREF="module-dict.html#Compatibility"
-REL="Help"
-><STRONG>Compatibility:</STRONG></A> Available in Apache 1.2 and later.
-</P>
-
-
- <H2>Summary</H2>
- <P>
- This module controls the setting of the <CODE>Expires</CODE> HTTP
- header in server responses. The expiration date can set to be
- relative to either the time the source file was last modified, or to
- the time of the client access.
- </P>
- <P>
- The <CODE>Expires</CODE> HTTP header is an instruction to the client
- about the document's validity and persistence. If cached, the document
- may be fetched from the cache rather than from the source until this
- time has passed. After that, the cache copy is considered
- &quot;expired&quot; and invalid, and a new copy must be obtained from
- the source.
- </P>
-
- <H2>Directives</H2>
- <P>
- <ul>
- <LI><A
- HREF="#expiresactive"
- >ExpiresActive</A>
- </LI>
- <LI><A
- HREF="#expiresbytype"
- >ExpiresByType</A>
- </LI>
- <LI><A
- HREF="#expiresdefault"
- >ExpiresDefault</A>
- </LI>
- </ul>
-
- <H2>
- <A NAME="AltSyn">Alternate Interval Syntax</A>
- </H2>
- <P>
- The
- <A
- HREF="#expiresdefault"
- ><SAMP>ExpiresDefault</SAMP></A>
- and
- <A
- HREF="#expiresbytype"
- ><SAMP>ExpiresByType</SAMP></A>
- directives can also be defined in a more readable syntax of the form:
- </P>
- <DL>
- <DD><CODE>ExpiresDefault "&lt;base&gt; [plus] {&lt;num&gt; &lt;type&gt;}*"
- <BR>
- ExpiresByType type/encoding "&lt;base&gt; [plus]
- {&lt;num&gt; &lt;type&gt;}*"</CODE>
- </DD>
- </DL>
- <P>
- where &lt;base&gt; is one of:
- </P>
- <MENU>
- <LI><SAMP>access</SAMP>
- </LI>
- <LI><SAMP>now</SAMP> (equivalent to '<SAMP>access</SAMP>')
- </LI>
- <LI><SAMP>modification</SAMP>
- </LI>
- </MENU>
- <P>
- The '<SAMP>plus</SAMP>' keyword is optional. &lt;num&gt; should be an
- integer value [acceptable to <SAMP>atoi()</SAMP>], and &lt;type&gt;
- is one of:
- </P>
- <MENU>
- <LI><SAMP>years</SAMP>
- </LI>
- <LI><SAMP>months</SAMP>
- </LI>
- <LI><SAMP>weeks</SAMP>
- </LI>
- <LI><SAMP>days</SAMP>
- </LI>
- <LI><SAMP>hours</SAMP>
- </LI>
- <LI><SAMP>minutes</SAMP>
- </LI>
- <LI><SAMP>seconds</SAMP>
- </LI>
- </MENU>
- <P>
- For example, any of the following directives can be used to make
- documents expire 1 month after being accessed, by default:
- </P>
- <DL>
- <DD><CODE>ExpiresDefault "access plus 1 month"
- <BR>
- ExpiresDefault "access plus 4 weeks"
- <BR>
- ExpiresDefault "access plus 30 days"</CODE>
- </DD>
- </DL>
- <P>
- The expiry time can be fine-tuned by adding several '&lt;num&gt;
- &lt;type&gt;' clauses:
- </P>
- <DL>
- <DD><CODE>ExpiresByType text/html "access plus 1 month 15 days 2 hours"
- <BR>
- ExpiresByType image/gif "modification plus 5 hours 3 minutes"</CODE>
- </DD>
- </DL>
- <P>
- Note that if you use a modification date based setting, the Expires
- header will <STRONG>not</STRONG> be added to content that does
- not come from a file on disk. This is due to the fact that there is
- no modification time for such content.
-
- <HR>
- <H2><A NAME="expiresactive">
- ExpiresActive directive
- </A></H2>
- <!--%plaintext &lt;?INDEX {\tt ExpiresActive} directive&gt; -->
- <P>
- <A
- HREF="directive-dict.html#Syntax"
- REL="Help"
- ><STRONG>Syntax:</STRONG></A> ExpiresActive on|off
- <BR>
- <A
- HREF="directive-dict.html#Context"
- REL="Help"
- ><STRONG>Context:</STRONG></A> server config, virtual host, directory,
- .htaccess
- <BR>
- <A
- HREF="directive-dict.html#Override"
- REL="Help"
- ><STRONG>Override:</STRONG></A> Indexes
- <BR>
- <A
- HREF="directive-dict.html#Status"
- REL="Help"
- ><STRONG>Status:</STRONG></A> Extension
- <BR>
- <A
- HREF="directive-dict.html#Module"
- REL="Help"
- ><STRONG>Module:</STRONG></A> mod_expires
- </P>
- <P>
- This directive enables or disables the generation of the
- <CODE>Expires</CODE> header for the document realm in question. (That
- is, if found in an <CODE>.htaccess</CODE> file, for instance, it
- applies only to documents generated from that directory.) If set to
- <EM><CODE>Off</CODE></EM>, no <CODE>Expires</CODE> header will be
- generated for any document in the realm (unless overridden at a lower
- level, such as an <CODE>.htaccess</CODE> file overriding a server
- config file). If set to <EM><CODE>On</CODE></EM>, the header will be
- added to served documents according to the criteria defined by the
- <A
- HREF="#expiresbytype"
- >ExpiresByType</A>
- and
- <A
- HREF="#expiresdefault"
- >ExpiresDefault</A>
- directives (<EM>q.v.</EM>).
- </P>
- <P>
- Note that this directive does not guarantee that an
- <CODE>Expires</CODE> header will be generated. If the criteria aren't
- met, no header will be sent, and the effect will be as though this
- directive wasn't even specified.
- </P>
- <HR>
- <H2><A NAME="expiresbytype">
- ExpiresByType directive
- </A></H2>
- <!--%plaintext &lt;?INDEX {\tt ExpiresByType} directive&gt; -->
- <P>
- <A
- HREF="directive-dict.html#Syntax"
- REL="Help"
- ><STRONG>Syntax:</STRONG></A> ExpiresByType <EM>MIME-type
- &lt;code&gt;seconds</EM>
- <BR>
- <A
- HREF="directive-dict.html#Context"
- REL="Help"
- ><STRONG>Context:</STRONG></A> server config, virtual host, directory,
- .htaccess
- <BR>
- <A
- HREF="directive-dict.html#Override"
- REL="Help"
- ><STRONG>Override:</STRONG></A> Indexes
- <BR>
- <A
- HREF="directive-dict.html#Status"
- REL="Help"
- ><STRONG>Status:</STRONG></A> Extension
- <BR>
- <A
- HREF="directive-dict.html#Module"
- REL="Help"
- ><STRONG>Module:</STRONG></A> mod_expires
- </P>
- <P>
- This directive defines the value of the <CODE>Expires</CODE> header
- generated for documents of the specified type (<EM>e.g.</EM>,
- <CODE>text/html</CODE>). The second argument sets the number of
- seconds that will be added to a base time to construct the expiration
- date.
- </P>
- <P>
- The base time is either the last modification time of the file, or the
- time of the client's access to the document. Which should be used is
- specified by the <CODE><EM>&lt;code&gt;</EM></CODE> field;
- <STRONG>M</STRONG> means that the file's last modification time should
- be used as the base time, and <STRONG>A</STRONG> means the client's
- access time should be used.
- </P>
- <P>
- The difference in effect is subtle. If <EM>M</EM> is used, all current
- copies of the document in all caches will expire at the same time,
- which can be good for something like a weekly notice that's always
- found at the same URL. If <EM>A</EM> is used, the date of expiration
- is different for each client; this can be good for image files that
- don't change very often, particularly for a set of related documents
- that all refer to the same images (<EM>i.e.</EM>, the images will be
- accessed repeatedly within a relatively short timespan).
- </P>
- <P>
- <STRONG>Example:</STRONG>
- </P>
- <P>
- <PRE>
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN"
+ "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
+
+<html xmlns="http://www.w3.org/1999/xhtml">
+ <head>
+ <meta name="generator" content="HTML Tidy, see www.w3.org" />
+
+ <title>Apache module mod_expires</title>
+ </head>
+ <!-- Background white, links blue (unvisited), navy (visited), red (active) -->
+
+ <body bgcolor="#FFFFFF" text="#000000" link="#0000FF"
+ vlink="#000080" alink="#FF0000">
+ <!--#include virtual="header.html" -->
+
+ <h1 align="CENTER">Module mod_expires</h1>
+
+ <p>This module provides for the generation of
+ <code>Expires</code> HTTP headers according to user-specified
+ criteria.</p>
+
+ <p><a href="module-dict.html#Status"
+ rel="Help"><strong>Status:</strong></a> Extension<br />
+ <a href="module-dict.html#SourceFile"
+ rel="Help"><strong>Source File:</strong></a>
+ mod_expires.c<br />
+ <a href="module-dict.html#ModuleIdentifier"
+ rel="Help"><strong>Module Identifier:</strong></a>
+ expires_module<br />
+ <a href="module-dict.html#Compatibility"
+ rel="Help"><strong>Compatibility:</strong></a> Available in
+ Apache 1.2 and later.</p>
+
+ <h2>Summary</h2>
+
+ <p>This module controls the setting of the <code>Expires</code>
+ HTTP header in server responses. The expiration date can set to
+ be relative to either the time the source file was last
+ modified, or to the time of the client access.</p>
+
+ <p>The <code>Expires</code> HTTP header is an instruction to
+ the client about the document's validity and persistence. If
+ cached, the document may be fetched from the cache rather than
+ from the source until this time has passed. After that, the
+ cache copy is considered "expired" and invalid, and a new copy
+ must be obtained from the source.</p>
+
+ <h2>Directives</h2>
+
+ <ul>
+ <li><a href="#expiresactive">ExpiresActive</a></li>
+
+ <li><a href="#expiresbytype">ExpiresByType</a></li>
+
+ <li><a href="#expiresdefault">ExpiresDefault</a></li>
+ </ul>
+
+ <h2><a id="AltSyn" name="AltSyn">Alternate Interval
+ Syntax</a></h2>
+
+ <p>The <a
+ href="#expiresdefault"><samp>ExpiresDefault</samp></a> and <a
+ href="#expiresbytype"><samp>ExpiresByType</samp></a> directives
+ can also be defined in a more readable syntax of the form:</p>
+
+ <dl>
+ <dd><code>ExpiresDefault "&lt;base&gt; [plus] {&lt;num&gt;
+ &lt;type&gt;}*"<br />
+ ExpiresByType type/encoding "&lt;base&gt; [plus]
+ {&lt;num&gt; &lt;type&gt;}*"</code></dd>
+ </dl>
+
+ <p>where &lt;base&gt; is one of:</p>
+
+ <ul>
+ <li><samp>access</samp></li>
+
+ <li><samp>now</samp> (equivalent to
+ '<samp>access</samp>')</li>
+
+ <li><samp>modification</samp></li>
+ </ul>
+
+ <p>The '<samp>plus</samp>' keyword is optional. &lt;num&gt;
+ should be an integer value [acceptable to <samp>atoi()</samp>],
+ and &lt;type&gt; is one of:</p>
+
+ <ul>
+ <li><samp>years</samp></li>
+
+ <li><samp>months</samp></li>
+
+ <li><samp>weeks</samp></li>
+
+ <li><samp>days</samp></li>
+
+ <li><samp>hours</samp></li>
+
+ <li><samp>minutes</samp></li>
+
+ <li><samp>seconds</samp></li>
+ </ul>
+
+ <p>For example, any of the following directives can be used to
+ make documents expire 1 month after being accessed, by
+ default:</p>
+
+ <dl>
+ <dd><code>ExpiresDefault "access plus 1 month"<br />
+ ExpiresDefault "access plus 4 weeks"<br />
+ ExpiresDefault "access plus 30 days"</code></dd>
+ </dl>
+
+ <p>The expiry time can be fine-tuned by adding several
+ '&lt;num&gt; &lt;type&gt;' clauses:</p>
+
+ <dl>
+ <dd><code>ExpiresByType text/html "access plus 1 month 15
+ days 2 hours"<br />
+ ExpiresByType image/gif "modification plus 5 hours 3
+ minutes"</code></dd>
+ </dl>
+
+ <p>Note that if you use a modification date based setting, the
+ Expires header will <strong>not</strong> be added to content
+ that does not come from a file on disk. This is due to the fact
+ that there is no modification time for such content.</p>
+ <hr />
+
+ <h2><a id="expiresactive" name="expiresactive">ExpiresActive
+ directive</a></h2>
+ <!--%plaintext &lt;?INDEX {\tt ExpiresActive} directive&gt; -->
+
+ <p><a href="directive-dict.html#Syntax"
+ rel="Help"><strong>Syntax:</strong></a> ExpiresActive
+ on|off<br />
+ <a href="directive-dict.html#Context"
+ rel="Help"><strong>Context:</strong></a> server config, virtual
+ host, directory, .htaccess<br />
+ <a href="directive-dict.html#Override"
+ rel="Help"><strong>Override:</strong></a> Indexes<br />
+ <a href="directive-dict.html#Status"
+ rel="Help"><strong>Status:</strong></a> Extension<br />
+ <a href="directive-dict.html#Module"
+ rel="Help"><strong>Module:</strong></a> mod_expires</p>
+
+ <p>This directive enables or disables the generation of the
+ <code>Expires</code> header for the document realm in question.
+ (That is, if found in an <code>.htaccess</code> file, for
+ instance, it applies only to documents generated from that
+ directory.) If set to <em><code>Off</code></em>, no
+ <code>Expires</code> header will be generated for any document
+ in the realm (unless overridden at a lower level, such as an
+ <code>.htaccess</code> file overriding a server config file).
+ If set to <em><code>On</code></em>, the header will be added to
+ served documents according to the criteria defined by the <a
+ href="#expiresbytype">ExpiresByType</a> and <a
+ href="#expiresdefault">ExpiresDefault</a> directives
+ (<em>q.v.</em>).</p>
+
+ <p>Note that this directive does not guarantee that an
+ <code>Expires</code> header will be generated. If the criteria
+ aren't met, no header will be sent, and the effect will be as
+ though this directive wasn't even specified.</p>
+ <hr />
+
+ <h2><a id="expiresbytype" name="expiresbytype">ExpiresByType
+ directive</a></h2>
+ <!--%plaintext &lt;?INDEX {\tt ExpiresByType} directive&gt; -->
+
+ <p><a href="directive-dict.html#Syntax"
+ rel="Help"><strong>Syntax:</strong></a> ExpiresByType
+ <em>MIME-type &lt;code&gt;seconds</em><br />
+ <a href="directive-dict.html#Context"
+ rel="Help"><strong>Context:</strong></a> server config, virtual
+ host, directory, .htaccess<br />
+ <a href="directive-dict.html#Override"
+ rel="Help"><strong>Override:</strong></a> Indexes<br />
+ <a href="directive-dict.html#Status"
+ rel="Help"><strong>Status:</strong></a> Extension<br />
+ <a href="directive-dict.html#Module"
+ rel="Help"><strong>Module:</strong></a> mod_expires</p>
+
+ <p>This directive defines the value of the <code>Expires</code>
+ header generated for documents of the specified type
+ (<em>e.g.</em>, <code>text/html</code>). The second argument
+ sets the number of seconds that will be added to a base time to
+ construct the expiration date.</p>
+
+ <p>The base time is either the last modification time of the
+ file, or the time of the client's access to the document. Which
+ should be used is specified by the
+ <code><em>&lt;code&gt;</em></code> field; <strong>M</strong>
+ means that the file's last modification time should be used as
+ the base time, and <strong>A</strong> means the client's access
+ time should be used.</p>
+
+ <p>The difference in effect is subtle. If <em>M</em> is used,
+ all current copies of the document in all caches will expire at
+ the same time, which can be good for something like a weekly
+ notice that's always found at the same URL. If <em>A</em> is
+ used, the date of expiration is different for each client; this
+ can be good for image files that don't change very often,
+ particularly for a set of related documents that all refer to
+ the same images (<em>i.e.</em>, the images will be accessed
+ repeatedly within a relatively short timespan).</p>
+
+ <p><strong>Example:</strong></p>
+<pre>
ExpiresActive On # enable expirations
ExpiresByType image/gif A2592000 # expire GIF images after a month
# in the client's cache
ExpiresByType text/html M604800 # HTML documents are good for a
# week from the time they were
# changed, period
- </PRE>
- </P>
- <P>
- Note that this directive only has effect if <CODE>ExpiresActive
- On</CODE> has been specified. It overrides, for the specified MIME
- type <EM>only</EM>, any expiration date set by the
- <A
- HREF="#expiresdefault"
- >ExpiresDefault</A>
- directive.
- </P>
- <P>
- You can also specify the expiration time calculation using an
- <A
- HREF="#AltSyn"
- >alternate syntax</A>,
- described later in this document.
- </P>
- <HR>
- <H2><A NAME="expiresdefault">
- ExpiresDefault directive
- </A></H2>
- <!--%plaintext &lt;?INDEX {\tt ExpiresDefault} directive&gt; -->
- <P>
- <A
- HREF="directive-dict.html#Syntax"
- REL="Help"
- ><STRONG>Syntax:</STRONG></A> ExpiresDefault <EM>&lt;code&gt;seconds</EM>
- <BR>
- <A
- HREF="directive-dict.html#Context"
- REL="Help"
- ><STRONG>Context:</STRONG></A> server config, virtual host, directory,
- .htaccess
- <BR>
- <A
- HREF="directive-dict.html#Override"
- REL="Help"
- ><STRONG>Override:</STRONG></A> Indexes
- <BR>
- <A
- HREF="directive-dict.html#Status"
- REL="Help"
- ><STRONG>Status:</STRONG></A> Extension
- <BR>
- <A
- HREF="directive-dict.html#Module"
- REL="Help"
- ><STRONG>Module:</STRONG></A> mod_expires
- </P>
- <P>
- This directive sets the default algorithm for calculating the
- expiration time for all documents in the affected realm. It can be
- overridden on a type-by-type basis by the
- <A
- HREF="#expiresbytype"
- >ExpiresByType</A>
- directive. See the description of that directive for details about
- the syntax of the argument, and the
- <A
- HREF="#AltSyn"
- >alternate syntax</A>
- description as well.
- </P>
-
- <!--#include virtual="footer.html" -->
- </BODY>
-</HTML>
+
+</pre>
+ <br />
+ <br />
+
+
+ <p>Note that this directive only has effect if
+ <code>ExpiresActive On</code> has been specified. It overrides,
+ for the specified MIME type <em>only</em>, any expiration date
+ set by the <a href="#expiresdefault">ExpiresDefault</a>
+ directive.</p>
+
+ <p>You can also specify the expiration time calculation using
+ an <a href="#AltSyn">alternate syntax</a>, described later in
+ this document.</p>
+ <hr />
+
+ <h2><a id="expiresdefault" name="expiresdefault">ExpiresDefault
+ directive</a></h2>
+ <!--%plaintext &lt;?INDEX {\tt ExpiresDefault} directive&gt; -->
+
+ <p><a href="directive-dict.html#Syntax"
+ rel="Help"><strong>Syntax:</strong></a> ExpiresDefault
+ <em>&lt;code&gt;seconds</em><br />
+ <a href="directive-dict.html#Context"
+ rel="Help"><strong>Context:</strong></a> server config, virtual
+ host, directory, .htaccess<br />
+ <a href="directive-dict.html#Override"
+ rel="Help"><strong>Override:</strong></a> Indexes<br />
+ <a href="directive-dict.html#Status"
+ rel="Help"><strong>Status:</strong></a> Extension<br />
+ <a href="directive-dict.html#Module"
+ rel="Help"><strong>Module:</strong></a> mod_expires</p>
+
+ <p>This directive sets the default algorithm for calculating
+ the expiration time for all documents in the affected realm. It
+ can be overridden on a type-by-type basis by the <a
+ href="#expiresbytype">ExpiresByType</a> directive. See the
+ description of that directive for details about the syntax of
+ the argument, and the <a href="#AltSyn">alternate syntax</a>
+ description as well.</p>
+ <!--#include virtual="footer.html" -->
+ </body>
+</html>
+