spacer graphic spacer graphic x10icon graphic [Bar]


More About MIME

 

As discussed last week in Tracker's Identify Command, (and in the IconWorld story "The Registrar Icon"), MIME types are used extensively throughout the BeOS. MIME types are at the bottom of how the Tracker decides what application to launch when you double-click a file. All BeOS applications have a unique signature, that is based on MIME types. In Release 3, icon highlighting and the new Open With function are done using MIME type information.

What the heck is a MIME type?

The acronym MIME stands for Multipurpose Internet Mail Extensions. Originally (RFC 1521), it was designed as a way to add multiple attachments, of any of a variety of different data types, to e-mail messages. And it's used for this today by many e-mailer clients, including BeMail (though many clients still do not support it).

A MIME type is a way of designating the data type of the enclosure, or file, or whatever the MIME part is. MIME types are composed in a hierarchical, major/minor format, where the major portion is the "supertype" and the minor portion is the more specific sub-type.

For example, all files stored as plain ASCII text belong to the supertype "text". But when you have a text file, it can be any number of different flavors of text. HTML files are text files, but they contain structural information (stored as plain text tags) as well as the "content" of the file. C++ source code files are plain text files, but are generally used in a different context than plain text or HTML files. Etc.

Each of these different kinds of text files deserve different classifications inside the general classification of "text", which is why they each get different sub-types. You might have a full MIME designation of text/html for the HTML files, text/x-source-code for the C++ files, and text/plain for ordinary text files created with StyledEdit, the amazing Pe, or the supercool Eddie.

There are a variety of recognized, standard MIME types (such as text/html), but the standard allows for extending the sub-types simply by prepending an "x-" to the beginning of the sub-type (as in text/x-source-code).

You can see what MIME types your BeOS system knows about by opening the FileTypes preferences application, and viewing the outline list view in the top-left of the FileTypes panel:

FileTypes panel

If you're courageous, you can change a MIME type's preferred application, causing a different application to open files of that type when you double-click them. See the BeOS User's Guide for more information about how to do this, but be cautious about making changes if you're not sure about what you're doing.

Next week: What happens when MIME types go bad. Shhh, watch out for the MIME Police!


Copyright © 1999 by Be, Inc. All rights reserved. Legal information (includes icon usage info).
Comments, questions, or confessions about our site? Please write the Webmaster.