Sign Up

Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.

Have an account? Sign In

Have an account? Sign In Now

Sign In

Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.

Sign Up Here

Forgot Password?

Don't have account, Sign Up Here

Forgot Password

Lost your password? Please enter your email address. You will receive a link and will create a new password via email.

Have an account? Sign In Now

You must login to ask a question.

Forgot Password?

Need An Account, Sign Up Here

Please briefly explain why you feel this question should be reported.

Please briefly explain why you feel this answer should be reported.

Please briefly explain why you feel this user should be reported.

Sign InSign Up

The Archive Base

The Archive Base Logo The Archive Base Logo

The Archive Base Navigation

  • SEARCH
  • Home
  • About Us
  • Blog
  • Contact Us
Search
Ask A Question

Mobile menu

Close
Ask a Question
  • Home
  • Add group
  • Groups page
  • Feed
  • User Profile
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Buy Points
  • Users
  • Help
  • Buy Theme
  • SEARCH
Home/ Questions/Q 7893101
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: June 3, 20262026-06-03T07:02:22+00:00 2026-06-03T07:02:22+00:00

I have a PHP script which downloads files to the client, in a new

  • 0

I have a PHP script which downloads files to the client, in a new window. It works great in firefox, but in IE8 the window opens and then closes immediately. Note this ONLY happens for some files (like text/plain type), but for others (eg: application/pdf) it works fine.

My PHP script adds the http headers shown below (plus a few added by my proxy server are shown). I can’t figure out what’s wrong. After playing with headers in php I find that removing Content-Type and Content-Disposition seems to have an impact, but I’m just messing around and can’t really understand what’s wrong.

I grabbed the header from Firefox as shown below. Can anyone see something which would cause IE to close immediately I tried setting the mime type to application/text but no difference.

HTTP/1.0 200 OK
Date: Sat, 21 Apr 2012 21:02:13 GMT
Server: Apache
Pragma: public
Expires: 0
Cache-Control: public
Content-Description: File Transfer
Content-Disposition: attachment; filename="Sample_Text_File.txt"
Content-Transfer-Encoding: binary
Vary: Accept-Encoding
Content-Encoding: gzip
Content-Length: 47
Content-Type: text/plain
X-Cache: MISS from firewall.mydomain.ca
X-Cache-Lookup: MISS from firewall.mydomain.ca:3128
Via: 1.0 firewall.mydomain.ca (squid/3.0.STABLE7)
Proxy-Connection: close
  • 1 1 Answer
  • 0 Views
  • 0 Followers
  • 0
Share
  • Facebook
  • Report

Leave an answer
Cancel reply

You must login to add an answer.

Forgot Password?

Need An Account, Sign Up Here

1 Answer

  • Voted
  • Oldest
  • Recent
  • Random
  1. Editorial Team
    Editorial Team
    2026-06-03T07:02:23+00:00Added an answer on June 3, 2026 at 7:02 am

    It appears to be IE’s anti-popup technology. Even though I marked the site as sage in IE’s settings, it still blocks..

    Solution was to start the download in the same windows (not _blank) and the IE is happy. Every other browser I you can open in a new window.

    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

I have a PHP search script which I've altered slightly and works well for
I have a php script, which downloads, rescales and stores an image using the
I have a php-script, which uploads mp3-files on my server. I use 'uploadify' for
I have a php script which accesses a MSSQL2005 database, reads some data from
I have this PHP script which i'm grabbing images from a directory and displaying
I have a php script which saves the original image, then resizes it -
I have a PHP script which creates and listens on a port for connections
I have a PHP script which is generating buttons to each content schedule. The
Here I have a simple php script which displays some values from a database
I have some php script updater.php which does some job for 1-2 minutes. Finishing

Explore

  • Home
  • Add group
  • Groups page
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Users
  • Help
  • SEARCH

Footer

© 2021 The Archive Base. All Rights Reserved
With Love by The Archive Base

Insert/edit link

Enter the destination URL

Or link to existing content

    No search term specified. Showing recent items. Search or use up and down arrow keys to select an item.