MIME Types and .htaccess
Please choose from the following questions.
If you can't find your question, please
let us
know and we'll answer it in e-mail and add it
to the FAQ.
- What are MIME types and how does the server
use them?
- How do I add a MIME type?
- How do I set it up so a directory
tree isn't shown when a someviews a directory in my account without
specifying a file name.
What are MIME types and how does the server use
them?
MIME types are a standard way of specifying the type of a document. A web
server uses MIME types to tell browsers what type of document the server
is sending. For files, the server determines the MIME type by the file's
extension (the file extension is the last part of file name, such as
.html, or .gif).
The standard set of MIME types is defined in the file
/usr/local/etc/httpd/conf/mime.types. However, you aren't
limited to the types defined there. MIME types may also be added through
the use of the AddType directive in .htaccess files.
How do I add a MIME type?
A MIME type can be added by creating a file called .htaccess in the directory containing the document you want to set the MIME
type for. The file should contain a line in the following format:
AddType mimetype ext
Where mimetype is a MIME type like
application/futuresplash
and ext is a file extension like spl
How do I set it up so a directory
tree isn't shown when a someviews a directory in my account without
specifying a file name.
You can either upload an index.html file to the directory, or add the
following to your .htaccess file:
Options -Indexes
Back to FAQ Index
| |

Send E-Mail to: comments@dss-sites.com http://www.dss-sites.com
Dealer Support Services 203 Pine Street Fulton, NY 13069-2429 Phone: (315) 598-8082 Fax: (315) 422-3837 |