mod_mime.html revision d28e32b1bddce6e4ca3d8c305e265d6f76275b68
45818ee124adeaaf947698996b4f4c722afc6d1fMatthew Ahrens<!DOCTYPE HTML PUBLIC "-//IETF//DTD HTML 2.0//EN">
45818ee124adeaaf947698996b4f4c722afc6d1fMatthew Ahrens<!--#include virtual="header.html" -->
45818ee124adeaaf947698996b4f4c722afc6d1fMatthew AhrensThis module is contained in the <code>mod_mime.c</code> file, and is
45818ee124adeaaf947698996b4f4c722afc6d1fMatthew Ahrenscompiled in by default. It provides for determining the types of files
45818ee124adeaaf947698996b4f4c722afc6d1fMatthew Ahrensfrom the filename.
45818ee124adeaaf947698996b4f4c722afc6d1fMatthew AhrensThis module is used to determine the mime types of documents. Some mime
45818ee124adeaaf947698996b4f4c722afc6d1fMatthew Ahrenstypes indicate special processing to be performed by the server, otherwise
45818ee124adeaaf947698996b4f4c722afc6d1fMatthew Ahrensthe type is returned to the client so that the browser can deal with
45818ee124adeaaf947698996b4f4c722afc6d1fMatthew Ahrensthe document appropriately.<p>
45818ee124adeaaf947698996b4f4c722afc6d1fMatthew AhrensThe filename of a document is treated as being composed of a basename followed
45818ee124adeaaf947698996b4f4c722afc6d1fMatthew Ahrensby some extensions, in the following order:
45818ee124adeaaf947698996b4f4c722afc6d1fMatthew Ahrens<blockquote><em>base.type.language.enc</em></blockquote>
45818ee124adeaaf947698996b4f4c722afc6d1fMatthew AhrensThe <em>type</em> extension sets the type of the document; types are defined
45818ee124adeaaf947698996b4f4c722afc6d1fMatthew Ahrensin the <A HREF="#typesconfig">TypesConfig</A> file and by the
45818ee124adeaaf947698996b4f4c722afc6d1fMatthew Ahrens<A HREF="#addtype">AddType</A> directive. The <em>language</em> extension
45818ee124adeaaf947698996b4f4c722afc6d1fMatthew Ahrenssets the language of the document, as defined by the
45818ee124adeaaf947698996b4f4c722afc6d1fMatthew Ahrens<A HREF="#addlanguage">AddLanguage</A> directive. Finally, the
45818ee124adeaaf947698996b4f4c722afc6d1fMatthew Ahrens<em>enc</em> directive sets the encoding of the document, as defined by
45818ee124adeaaf947698996b4f4c722afc6d1fMatthew Ahrensthe <A HREF="#addencoding">AddEncoding</A> directive.
45818ee124adeaaf947698996b4f4c722afc6d1fMatthew Ahrens<A name="addencoding"><h2>AddEncoding</h2></A>
45818ee124adeaaf947698996b4f4c722afc6d1fMatthew Ahrens<!--%plaintext <?INDEX {\tt AddEncoding} directive> -->
45818ee124adeaaf947698996b4f4c722afc6d1fMatthew Ahrens<strong>Syntax:</strong> AddEncoding <em>mime-enc extension extension...</em><br>
45818ee124adeaaf947698996b4f4c722afc6d1fMatthew Ahrens<Strong>Context:</strong> server config, virtual host, directory, .htaccess<br>
called, you might put the following into access.conf:
<!--#include virtual="footer.html" -->