19.24. mod_mimeThe mod_mime module contains directives that help to organize various MIME types on the server.
AddEncoding encoding extension ... [server config, or within <VirtualHost> or <Directory>, or .htaccess] Allows you to specify which MIME encodings should be associated with documents from your server. Encodings beginning with x- are used for unofficial encodings. For example: AddEncoding x-gzip gz
AddHandler handler-name extension ... [server config, or within <VirtualHost> or <Directory>, or .htaccess] Maps one or more filename extensions to a specific handler for the server. For example, for CGI scripts, you might use the following: AddHandler cgi-script cgi
AddLanguage mime-lang extension ... [server config, or within <VirtualHost> or <Directory>, or .htaccess] Specifies that a certain extension should be associated with a specific language for purposes of content negotiation. For example, to associate the extension .francais with French documents, use the following setting: AddLanguage fr .francais
AddType mime-type extension ... [server config, or within <VirtualHost> or <Directory>, or .htaccess] Specifies a MIME type and subtype to be associated with certain file extensions. For example, if you want to serve a Microsoft Word document: AddType application/msword .doc AddType directives overrides any extension-to-type mappings in your mime.types file.
DefaultLanguage language [server config, or within <VirtualHost> or <Directory>, or .htaccess] Specifies the default language for any files that are not associated with a particular language via AddLanguage.
ForceType mime_type [Within <Directory>, or .htaccess] Specifies that all files in this directory should be served with the specified type. Appropriate for inclusion in .htaccess files or within <Directory> section directives.
[Within <Directory>, or .htaccess] Removes any associated encodinges for files matching the specified extensions.
[Within <Directory>, or .htaccess] Removes any associated handlers for files matching the specified extensions.
[Within <Directory>, or .htaccess] Removes any associated MIME types for files matching the specified extensions.
SetHandler handler [Within <Directory>, or .htaccess] Specifies that all files in the directory should be passed through the specified handler. Values are:
TypesConfig filename [server config] Specifies the location of the MIME types file. As with other configuration paths, the location may be given as either an absolute path or a relative path to the ServerRoot directory. The default is: TypesConfig conf/mime.types Copyright © 2003 O'Reilly & Associates. All rights reserved. |
|