.htmlis informally understood to mean that the file is an HTML page, there is no requirement that it mean this, and many HTML pages have different file extensions.
In the HTTP protocol used by web browsers to talk to web servers, the "file extension" of the URL is not used to determine the type of information that the server will return. Indeed, there may be no file extension at all at the end of the URL.
Instead, the web server specifies the correct MIME type using a
Content-type: header when it responds to the web
browser's HTTP request.
Here are some examples of common mime types seen on the web:
|Type||Common File Extension||Purpose|
|audio/mpeg||.mp3||MPEG Audio File|
|application/octet-stream||.exe||Best for downloads that should just be saved to disk|
MIME stands for "Multimedia Internet Mail Extensions." MIME was originally invented to solve a similar problem for email attachments.
Got a LiveJournal account? Keep up with the latest articles in this FAQ by adding our syndicated feed to your friends list!