Re: Stream download problem
| From: | Prathaban Mookiah | Date: | Wed, 21 Jun 2006 01:54:45 +0000 |
| Subject: | Re: Stream download problem | ||
| References: | 1 | Groups: | php.general |
| Request: | Send a blank email to php-general+get-238447@lists.php.net to get a copy of this message | ||
Micheal,
I ran into this problem too. A easy workaround is to right click and choose
'save as' which worked for me.
For complete information on this you may want to have a look at http://
support.
microsoft.com/default.aspx/kb/279667
Cheers,
Prathap
---------- Original Message -----------
From: Michael Satterwhite <michael@weblore.com>
To: PHP Users <php-general@lists.php.net>
Sent: Tue, 20 Jun 2006 19:32:17 -0500
Subject: [PHP] Stream download problem
> I have a site that generates a file to be streamed down. The
> relevant code is:
> ----------------------------------------------------------
> header("Content-type: application/vnd.ms-excel");
> header("Content-disposition: attachment; filename=$EXPORT_TIME.txt");
> header("Content-disposition: attachment");
> header("Pragma: no-cache");
> header("Expires: 0");
> echo $filestring;
> die();
> -----------------------------------------------------------
>
> $EXPORT_TIME has been set to a valid filename in earlier part of
> script. The script has been called by the user clicking on a line
> similar to <a href="easy.php?download=stream&dltype=full.
>
> If the browser in use is Firefox, Mozilla, or almost anything, it
> works correctly. If the browser is Internet Explorer, the download
> fails. It appears in that case that the filename expected is the
> full url used to call the page (e.g.
> easy.php?download=stream&dltype=full) which is an invalid filename,
> hence the failure.
>
> ...and before you suggest it, *NO*, I cannot tell my client that
> they can't use Internet Explorer.
>
> Can anyone offer any help?
> ---Michael
>
> --
> PHP General Mailing List (http://www.php.net/)
> To unsubscribe, visit: http://www.php.net/unsub.php
------- End of Original Message -------