Microsoft Overloads MIME Types, Breaks Safari

Safari Downloads Window For some time, any time I downloaded a Microsoft Office document in Safari, the browser appended an extra filename extension to the saved download, which turned the Office Document into an Office Template. A Word Document gets a .dot suffix, a Powerpoint slide show gets .pot, and an Excel spreadsheet gets .xla, which turns it into an add-in library which is really not what that file is. ?Devastating? No. Annoying? For sure yes. Life is too short to have to munge file name extensions all the time, and this is a Mac, right, so stuff should just work.?

Fortunately, a Google trip across some web forums leads to the cause of the problem, which in itself is an interesting illustration about how intricate even Personal Computers have become, and how easy it is to break something. ?The root of the problem seems to be the Universal Type definitions that come with the Microsoft Office 2008 programs. Like all programs,?Word and others have?file type definitions?in the info.plist file inside their application package. According to?this discussion?at Apple, both the .doc and .dot file types (pre-2007 Word Document and pre-2007 Word Template, respectively) have the MIME type application/msword associated, and Safari, or the operating system service that Safari consults, obviously pick the wrong one.?Apparently, all you need to do to make this problem go away is to?eliminate?the MIME type key-value pair from the?offending?file type so that there once again is a one-on-one mapping of MIME type to filename extension.

?

Remember how the Mac used to have Type and Creator information that came with the document files? These still exist, but now have gotten company from filename extensions the MS-DOS world grew up with, and MIME types that come with the Web. ?A Universal Type definition bundled with the application (Word et. al.) ties all of these together: the?classic W8BN document type to the modern com.microsoft.word.doc to the filename extension (doc) and the MIME type (application/msword) so that the OS and finder, and any program that uses these services, can make sense of these documents in any representation. In theory. Unless something gets multiple definitions and everything breaks.

I think Microsoft should fix this.

Be Sociable, Share!