[ic] correct mime type for .exe with MSIE

Jonathan Clark interchange-users@interchange.redhat.com
Wed Apr 10 03:50:01 2002


> I am trying to find out how to make MSIE download a .exe file with the
> extension intact.  Using the IC built in file delivery mechanism, it feeds
> the file directly to the browser, and for some reason MSIE prompts you to
> download the file without the extension.  This is using
> application/octet-stream as the mime type.  What it looks like is that
> MSIE can't determine what type of file it is, and therefore can't
> determine what extension to give it.  Since the content is fed directly to
> the browser it doesn't have a filename in the url to go by.  If you give
> it a mime type it knows an extension for it will name that file with that
> extension.  Problem is there is no specific mime type for .exe that I know
> of.  Netscape and Opera seem to work fine...

AFAIK a .exe is just an application/octet-stream. Are you specifying the
filename in the header?

In a custome download routine I do:

[tag op=header interpolate=1]
Content-type: application/octet-stream
Content-disposition: inline; filename=[scratch file_name]
Content-length: [scratch file_size]
[/tag]

..which works fine for MSIE.

Jonathan
Webmaint.