From: Igor Galić Date: Sat, 18 Sep 2010 21:41:04 +0000 (+0000) Subject: Explanation on how to prioritize mime-types on the serverside with AddType. X-Git-Tag: 2.3.9~488 X-Git-Url: http://git.ipfire.org/cgi-bin/gitweb.cgi?a=commitdiff_plain;h=1e114604085c6f6aea7d924b22d03866b71ec0fa;p=thirdparty%2Fapache%2Fhttpd.git Explanation on how to prioritize mime-types on the serverside with AddType. git-svn-id: https://svn.apache.org/repos/asf/httpd/httpd/trunk@998553 13f79535-47bb-0310-9956-ffa450edef68 --- diff --git a/docs/manual/mod/mod_mime.html.en b/docs/manual/mod/mod_mime.html.en index 350c29b111a..666892e19f4 100644 --- a/docs/manual/mod/mod_mime.html.en +++ b/docs/manual/mod/mod_mime.html.en @@ -537,8 +537,13 @@ type type to use for filenames containing extension. This mapping is added to any already in force, overriding any mappings that already exist for the same - extension. This directive can be used to add mappings - not listed in the media types file (see the TypesConfig directive).

+ extension.

+ +
+ It is recommended that new media types be added using the + AddType directive rather than changing the + TypesConfig file. +

Example

AddType image/gif .gif @@ -550,17 +555,24 @@ type AddType image/jpeg jpeg jpg jpe

-
- It is recommended that new media types be added using the - AddType directive rather than changing the - TypesConfig file. -
-

The extension argument is case-insensitive and can be specified with or without a leading dot. Filenames may have multiple extensions and the extension argument will be compared against each of them.

+

A simmilar effect to mod_negotiation's + LanguagePriority + can be achieved by qualifying a media-type with + qs:

+ +

Example

+ Addtype application/rss+xml;qs=0.8 .xml +

+ +

This is useful in situations, e.g. when a client + requesting Accept: */* can not actually processes + the content returned by the server.

+

This directive primarily configures the content types generated for static files served out of the filesystem. For resources other than static files, where the generator of the response typically specifies @@ -570,6 +582,7 @@ type

See also

top
diff --git a/docs/manual/mod/mod_mime.xml b/docs/manual/mod/mod_mime.xml index c94681ea7e1..d9091a1fc3c 100644 --- a/docs/manual/mod/mod_mime.xml +++ b/docs/manual/mod/mod_mime.xml @@ -529,9 +529,13 @@ type type to use for filenames containing extension. This mapping is added to any already in force, overriding any mappings that already exist for the same - extension. This directive can be used to add mappings - not listed in the media types file (see the TypesConfig directive).

+ extension.

+ + + It is recommended that new media types be added using the + AddType directive rather than changing the + TypesConfig file. + Example AddType image/gif .gif @@ -543,18 +547,25 @@ type AddType image/jpeg jpeg jpg jpe - - It is recommended that new media types be added using the - AddType directive rather than changing the - TypesConfig file. - -

The extension argument is case-insensitive and can be specified with or without a leading dot. Filenames may have multiple extensions and the extension argument will be compared against each of them.

+

A simmilar effect to mod_negotiation's + LanguagePriority + can be achieved by qualifying a media-type with + qs:

+ + Example + Addtype application/rss+xml;qs=0.8 .xml + + +

This is useful in situations, e.g. when a client + requesting Accept: */* can not actually processes + the content returned by the server.

+

This directive primarily configures the content types generated for static files served out of the filesystem. For resources other than static files, where the generator of the response typically specifies @@ -562,6 +573,7 @@ type ForceType +mod_negotiation