Mail Beyond Logo
Feed on
Posts
Comments

When trying to download a file that is auto-generated on the fly by a PHP script I wrote that sends excel headers, Internet Explorer users were getting the error:

Windows Internet Explorer
Internet Explorer cannot download [filename] from [website].
Internet Explorer was not able to open this Internet site. The requested site is either unavailable or cannot be found. Please try again later.

This is caused by doing a session_start(). If you don’t actually need a the session in your php file you can remove it, and IE users will be able to download whatever your PHP script is making. The problem is session_start() by default sends a cache control header including “no-store”. Internet Explorer has a bug with sending a cache header.

If you need the session, then before session_start(), add “session_cache_limiter(’none’);”

Problem solved!

If you found this helpful, help me by checking out the ads at the bottom of the page. Thank you!

Bookmark with: | del.icio.us | Digg it | Netscape | Newsvine | Yahoo MyWeb |

Trackback URI | Comments RSS

Leave a Reply

You must be logged in to post a comment.