[thelist] Forcing Download of Files With a Particular Extension

Peter Barrett peterb at corel.com
Fri Jan 26 13:51:42 CST 2001


ah! my bad. That morning thing :)...

If I remember correctly, IE 4 had a bug wherein it would examine the extention
*before* the http header, so this browser is a lost cause. ..

 Fragment from MS document:
 “You might think that setting the Content-Type to a type unknown to
Explorer would force the File Download dialog box. In fact, the Explorer
"sniffs" the data sent from the server and detects the type of file
being sent. If it recognizes the file type, it will behave according to
the user preference. At this point, there is no completely reliable way
to force the File Download dialog box to appear when downloading a file
to Internet Explorer. “

They fixed it in IE 5, but I think you need to change the Content Disposition
from 'inline' to 'attachment', as well as the Content Type to avoid a blank
window that looks like it's still loading after the download is complete... not
so sure about that one though... I didn't get that far :).

Cheers!
~pete


gregory.john.toland at census.gov wrote:

> I agree. That is why I was trying to set up the HTTP header of content-type
> or maybe content-disposition on our web server.  That way the server is
> telling the client what to do with the file.
>
> My situation:  The IE client is presented with an IFRAME filled with a list
> of files of a particular directory.  I hate to zip up all these files
> separately. I'm working on a NN solution since NN does not support IFRAME.
>
> Thanks though for your suggestion!
>
> Gregory J Toland
>  Sr. Systems Architect
>  CHM, Inc.
>  (301) 457-8058
>  tolan002 at census.gov





More information about the thelist mailing list