This should be a old problem about IE8 download problem. I used PHP to set the response header like:
header("Pragma: public");
header("Expires: 0");
header("Content-type: application/octet-stream");
header("Cache-Control: must-revalidate, post-check=0, pre-check=0");
header("Content-Length: ".strlen($content));
header("Content-Disposition: attachment; filename='$filename'");
and the Connection is close capture by Fiddler.
When I try to download the file with above header in IE8 (not in SSL), the message box :
"Internet Explorer was not able to open this Internet site. The requested site is either unavailable or cannot be found." pop up and download is stopped.
I searched on net and try lots of solutions but seems none of them works. Would there be any other solution for this problem?
PS: I have tried: Delete response header/reset contentType in header/ Add the site into trusted site/ set "Do not save encrypted pages to disk" as true.
Thanks.
In addition to Le-roy's answer:
I set
Cache-Control: private, max-age=1
and that fixed the issue for me.
From Le-roy's link, if any of these are set:
Cache-Control header with the tokens no-cache, no-store
Vary header that specifies almost anything
Pragma header that specifies exactly no-cache
IE download will fail.
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With