• 0

Force Download


Question

I created a webpage that will act as an installer on a CD i created. I needed a solution that was compatable with both PC and Mac, and flash wasn't an immediate option. Basically, I created the CD to auto launch a html file that will allow users to access files located on the cd. It will prompt them to save the files locally (which we encourage), and then they could open the files that are password protected. My only problem, its not downloading the files off the CD for some reason. Its trying to open them directly in the browser. It seems to be happening a lot on Netscape 4 for mac, but it is important this cd be compatable with ALL configurations if possible. The files in particular happen to be stuffit files, however it was doing the same thing when I had the files in regular office format.

I guess what I am asking is .. how can i FORCE a webpage to download a file instead of opening them in the browser.

Link to comment
Share on other sites

5 answers to this question

Recommended Posts

  • 0

Without a webserver involved, I don't think you can set mime-types. And I don't know of any way to invoke a download with js...

Link to comment
Share on other sites

  • 0
I have one solution, but I think it will only work in IE. Not sure if your just using Netscape only or both. Check this web site out. The file is called LaunchinIE and it is here http://www.whirlywiryweb.com/q%2Flaunchinie.asp

Hope this helps

Sidespike

Thanks, but i want it to "NOT" open in a broswer. :) Plus it doesn't work on the Mac platform .. I would need a strictly code based solution. Timdorr, can u explain the MINE types solution to me? I seen some posts on google about using the JS, but its really confusing.

Link to comment
Share on other sites

  • 0

MIME is basically a way of identifying the type of file when sending so the browser knows what to do with it. The mime-type normally gets sent with the HTTP headers, but you don't get that opportunity here. What's happening is that the browser doesn't have a MIME type, so it assumes text :s

Link to comment
Share on other sites

This topic is now closed to further replies.
  • Recently Browsing   0 members

    • No registered users viewing this page.