]> granicus.if.org Git - apache/blobdiff - docs/manual/mod/mod_mime.html
Merge in APR[-util] macros from branches/trunk-buildconf-noapr
[apache] / docs / manual / mod / mod_mime.html
index e71bd844e3fb436377c1a479820e02c63be014f3..db18e2febb6379a4139ba3e7040e1b71e34a4f18 100644 (file)
-<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 3.2 Final//EN">
-<HTML>
-<HEAD>
-<TITLE>Apache module mod_mime</TITLE>
-</HEAD>
+# GENERATED FROM XML -- DO NOT EDIT
 
-<!-- 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_mime</H1>
+URI: mod_mime.html.en
+Content-Language: en
+Content-type: text/html; charset=ISO-8859-1
 
-This module is contained in the <CODE>mod_mime.c</CODE> file, and is
-compiled in by default. It provides for determining the types of files
-from the filename.
-
-<h2>Summary</h2>
-
-This module is used to determine various bits of "meta information"
-about documents. This information relates to the content of the
-document and is returned to the browser or used in content-negotiation
-within the server. In addition, a "handler" can be set for a document,
-which determines how the document will be processed within the server.
-
-<P>
-
-The directives <A HREF="#addencoding">AddEncoding</A>, <A
-HREF="#addhandler">AddHandler</A>, <A
-HREF="#addlanguage">AddLanguage</A> and <A HREF="#addtype">AddType</A>
-are all used to map file extensions onto the meta-information for that
-file.  Respectively they set the content-encoding, handler,
-content-language and mime-type (content-type) of documents.  The
-directive <A HREF="#typesconfig">TypesConfig</A> is used to specify a
-file which also maps extensions onto mime types. The directives <A
-HREF="#forcetype">ForceType</A> and <A
-HREF="#sethandler">SetHandler</A> are used to associated all the files
-in a given location (e.g. a particular directory) onto a particular
-mime type or handler.
-
-<P>
-
-Files can have more than one extension, and the order of the
-extensions is normally irrelevant. For example, if the file
-<CODE>welcome.html.fr</CODE> maps onto content type text/html and
-language French then the file <CODE>welcome.fr.html</CODE> will map
-onto exactly the same information. The only exception to this is if an
-extension is given which Apache does not know how to handle. In this
-case it will "forget" about any information it obtained from
-extensions to the left of the unknown extension. So, for example, if
-the extensions fr and html are mapped to the appropriate language and
-type but extension xxx is not assigned to anything, then the file
-<CODE>welcome.fr.xxx.html</CODE> will be associated with content-type
-text/html but <EM>no</EM> language.
-
-<P>
-
-Note that changing the type or encoding of a file does not change the
-value of the <CODE>Last-Modified</CODE> header. Thus, previously cached
-copies may still be used by a client or proxy, with the previous headers.
-
-<P>
-
-Please note that changing a file's type or encoding does not change
-the value of the <CODE>Last-Modified</CODE> header. Previously cached
-copies may still be used by a client or proxy.
-
-<P>
-
-<h2> Directives</h2>
-<UL>
-<LI><A HREF="#addencoding">AddEncoding</A>
-<LI><A HREF="#addhandler">AddHandler</A>
-<LI><A HREF="#addlanguage">AddLanguage</A>
-<LI><A HREF="#addtype">AddType</A>
-<LI><A HREF="#forcetype">ForceType</A>
-<LI><A HREF="#sethandler">SetHandler</A>
-<LI><A HREF="#typesconfig">TypesConfig</A>
-</UL>
-<HR>
-
-
-<h2><A name="addencoding">AddEncoding</A></h2>
-<!--%plaintext &lt;?INDEX {\tt AddEncoding} directive&gt; -->
-<STRONG>Syntax:</STRONG> AddEncoding <EM>mime-enc extension extension...</EM><BR>
-<Strong>Context:</STRONG> server config, virtual host, directory, .htaccess<BR>
-<Strong>Override:</STRONG> FileInfo<BR>
-<STRONG>Status:</STRONG> Base<BR>
-<STRONG>Module:</STRONG> mod_mime<P>
-
-The AddEncoding directive adds to the list of filename extensions which
-filenames may end in for the specified encoding type. <EM>Mime-enc</EM>
-is the mime encoding to use for documents ending in <EM>extension</EM>.
-Example:
-<BLOCKQUOTE><CODE>
-AddEncoding x-gzip gz<BR>
-AddEncoding x-compress Z
-</CODE></BLOCKQUOTE>
-
-This will cause files ending in .gz to be marked as encoded using the x-gzip
-encoding, and .Z files to be marked as encoded with x-compress.<P><HR>
-
-<h2><A name="addhandler">AddHandler</A></h2>
-
-<STRONG>Syntax:</STRONG> AddHandler <EM>handler-name extension extension...</EM><BR>
-<STRONG>Context:</STRONG> server config, virtual host, directory, .htaccess<BR>
-<STRONG>Status:</STRONG> Base<BR>
-<STRONG>Module:</STRONG> mod_mime<BR>
-<STRONG>Compatibility:</STRONG> AddHandler is only available in Apache
-1.1 and later<P>
-
-<P>AddHandler maps the filename extensions <EM>extension</EM> to the
-<A HREF="../handler.html">handler</A>
-<EM>handler-name</EM>. For example, to activate CGI scripts
-with the file extension "<CODE>.cgi</CODE>", you might use:
-<PRE>
-    AddHandler cgi-script cgi
-</PRE>
-
-<P>Once that has been put into your srm.conf or httpd.conf file, any
-file ending with "<CODE>.cgi</CODE>" will be treated as a CGI
-program.</P>
-<HR>
-
-<h2><A name="addlanguage">AddLanguage</A></h2>
-<!--%plaintext &lt;?INDEX {\tt AddLanguage} directive&gt; -->
-<STRONG>Syntax:</STRONG> AddLanguage <EM>mime-lang extension extension...</EM><BR>
-<Strong>Context:</STRONG> server config, virtual host, directory, .htaccess<BR>
-<Strong>Override:</STRONG> FileInfo<BR>
-<STRONG>Status:</STRONG> Base<BR>
-<STRONG>Module:</STRONG> mod_mime<P>
-
-The AddLanguage directive adds to the list of filename extensions which
-filenames may end in for the specified content language. <EM>Mime-lang</EM>
-is the mime language of files with names ending <EM>extension</EM>,
-after any content encoding extensions have been removed. Example:
-<BLOCKQUOTE><CODE>
-AddEncoding x-compress Z<BR>
-AddLanguage en .en<BR>
-AddLanguage fr .fr<BR>
-</CODE></BLOCKQUOTE>
-
-Then the document <CODE>xxxx.en.Z</CODE> will be treated as being a compressed
-English document. Although the content language is reported to the client,
-the browser is unlikely to use this information. The AddLanguage directive
-is more useful for content negotiation, where the server returns one
-from several documents based on the client's language preference.<P><HR>
-
-<h2><A name="addtype">AddType</A></h2>
-<!--%plaintext &lt;?INDEX {\tt AddType} directive&gt; -->
-<STRONG>Syntax:</STRONG> AddType <EM>mime-type extension extension...</EM><BR>
-<Strong>Context:</STRONG> server config, virtual host, directory, .htaccess<BR>
-<Strong>Override:</STRONG> FileInfo<BR>
-<STRONG>Status:</STRONG> Base<BR>
-<STRONG>Module:</STRONG> mod_mime<P>
-
-The AddType directive adds to the list of filename extensions which
-filenames may end in for the specified content type. <EM>Mime-enc</EM>
-is the mime type to use for documents ending in <EM>extension</EM>.
-after content-encoding and language extensions have been removed. Example:
-<BLOCKQUOTE><CODE>
-AddType image/gif GIF
-</CODE></BLOCKQUOTE>
-It is recommended that new mime types be added using the AddType directive
-rather than changing the <A HREF="#typesconfig">TypesConfig</A> file.<P>
-Note that, unlike the NCSA httpd, this directive cannot be used to set the
-type of particular files.<P><HR>
-
-<h2><A name="forcetype">ForceType</A></h2>
-
-<STRONG>Syntax:</STRONG> ForceType <EM>media type</EM><BR>
-<STRONG>Context:</STRONG> directory, .htaccess<BR>
-<STRONG>Status:</STRONG> Base<BR>
-<STRONG>Module:</STRONG> mod_mime<BR>
-<STRONG>Compatibility:</STRONG> ForceType is only available in Apache
-1.1 and later.<P>
-
-<P>When placed into an <CODE>.htaccess</CODE> file or a
-<CODE>&lt;Directory&gt;</CODE> or <CODE>&lt;Location&gt;</CODE> section,
-this directive forces all matching files to be served
-as the content type given by <EM>media type</EM>. For example, if you
-had a directory full of GIF files, but did not want to label them all with
-".gif", you might want to use:
-<PRE>
-    ForceType image/gif
-</PRE>
-<P>Note that this will override any filename extensions that might
-media type.</P>
-
-<h2><A name="sethandler">SetHandler</A></h2>
-
-<STRONG>Syntax:</STRONG> SetHandler <EM>handler-name</EM><BR>
-<STRONG>Context:</STRONG> directory, .htaccess<BR>
-<STRONG>Status:</STRONG> Base<BR>
-<STRONG>Module:</STRONG> mod_mime<BR>
-<STRONG>Compatibility:</STRONG> SetHandler is only available in Apache
-1.1 and later.<P>
-
-<P>When placed into an <CODE>.htaccess</CODE> file or a
-<CODE>&lt;Directory&gt;</CODE> or <CODE>&lt;Location&gt;</CODE> section,
-this directive forces all matching files to be parsed through the
-<A HREF="../handler.html">handler</A>
-given by <EM>handler-name</EM>. For example, if you had a
-directory you wanted to be parsed entirely as imagemap rule files,
-regardless of extension, you might put the following into an
-<CODE>.htaccess</CODE> file in that directory:
-<PRE>
-    SetHandler imap-file
-</PRE>
-
-<P>Another example: if you wanted to have the server display a status
-report whenever a URL of <CODE>http://servername/status</CODE> was
-called, you might put the following into access.conf:
-<PRE>
-    &lt;Location /status&gt;
-    SetHandler server-status
-    &lt;/Location&gt;
-</PRE>
-<HR>
-
-<h2><A name="typesconfig">TypesConfig</A></h2>
-<!--%plaintext &lt;?INDEX {\tt TypesConfig} directive&gt; -->
-<STRONG>Syntax:</STRONG> TypesConfig <EM>filename</EM><BR>
-<STRONG>Default:</STRONG> <CODE>TypesConfig conf/mime.types</CODE><BR>
-<Strong>Context:</STRONG> server config<BR>
-<STRONG>Status:</STRONG> Base<BR>
-<STRONG>Module:</STRONG> mod_mime<P>
-
-The TypesConfig directive sets the location of the mime types configuration
-file. <EM>Filename</EM> is relative to the
-<A HREF="core.html#serverroot">ServerRoot</A>. This file sets the default list of
-mappings from filename extensions to content types; changing this file is not
-recommended. Use the <A HREF="#addtype">AddType</A> directive instead. The
-file contains lines in the format of the arguments to an AddType command:
-<BLOCKQUOTE><EM>mime-type extension extension ...</EM></BLOCKQUOTE>
-The extensions are lower-cased. Blank lines, and lines beginning with a hash
-character (`#') are ignored.<P>
-
-<!--#include virtual="footer.html" -->
-</BODY>
-</HTML>
+URI: mod_mime.html.fr
+Content-Language: fr
+Content-type: text/html; charset=ISO-8859-1
 
+URI: mod_mime.html.ja.utf8
+Content-Language: ja
+Content-type: text/html; charset=UTF-8