Hi,
If you are looking at downloading without a problem with any browser and any platform then you will need to send a header message forcing a download the below set of comands does that job for you
if ($startdownload == "yes") {
// this forces the download box for any download including image.
header("Content-type: application/x-ms-download;name=$url");
// or header("Content-type: application/force-download;name=$url");
// you can name the file to anything when downloaded as below
header("Content-Disposition: attachment; filename=$download_name"); // Netscape
//header("Content-Disposition: filename=$download_name");
header("Content-Transfer-Encoding: binary");
}
Try this.
Skizz wrote:
Hi guys, i've got a question.
I have made a download section on my site,
but i'm not happy with it.
It does the following,
You click on a file, then you see information about the filesize etc.. etc..
Then you click on the download button and
you go to another place and with the meta tag refresh i redirect to the file.
I've noticed that some computers&browsers have errors when trying to download these files.
I'm looking for a way to eliminate the 3rd step, when you click on the download button the download has to start and execute the tracking code..
Does anyone know how to?
if you don't know what i mean
http://www.clanbase.com/files.php3
try this for example.. this is the way i want it..