I use the following code to display a flash file:
header("Expires: Mon, 26 Jul 1997 05:00:00 GMT"); // some day in the past
header("Last-Modified: " . gmdate("D, d M Y H:i:s") . " GMT");
header("Content-Length: ".filesize($file));
header("Content-type: application/x-shockwave-flash");
header("Cache-Control: private");
header("Expires: 0");
@readfile($file);
exit();
It works like a charm in Firefox, but in IE, sometimes the movie loads, but most of the time, it doesnt. I right click and it says movie not loaded. Some of the files are 9MB, but the ones I am trying to load are less than 2MB. I am no longer using sessions on the page which was the original problem, so thats not it. Is it my headers thats causing this? I need to keep the flash files in a private directory, and this seems to be the only way to do this.
Thanks