Re: Redirect after download

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



Justin England wrote:
> I am writing a file download system and I need to be able to do a
> redirect after the download is finished.

The Redirect is sent as a header, before your download content.

The browser is free to act on that Redirect header and IGNORE the file
download content as soon as it sees the Redirect header.

The assumption by the browser for a Redirect header is that you are using
it for what it was desgined to mean: "This document has moved."

It should come as no surprise, then, that when you try to use the Redirect
header to get the browser to do something entirely different from what the
Redirect header was intended for, it doesn't work. :-)

If you control both the page you are coming from and Redirecting to, you
could have the destination page do the actual download, at least in
theory.

There again, not all browsers will work correctly when you try to cram a
download into HTML output all in one response to a single HTTP request.

So for those of use who use such browsers, *PLEASE* for the love of God,
give us a normal friggin' link to click on to get what we want.

Users with the fancy browsers will get their nifty
"download-and-transition-to-new-page" experience.

If you do not control the destination page, and can't make it do the
download (along with a link for us Luddites) then you are pretty much
stuck:  "You can't do that"  (Not reliably, anyway)

-- 
Like Music?
http://l-i-e.com/artists.htm

-- 
PHP General Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php


[Index of Archives]     [PHP Home]     [Apache Users]     [PHP on Windows]     [Kernel Newbies]     [PHP Install]     [PHP Classes]     [Pear]     [Postgresql]     [Postgresql PHP]     [PHP on Windows]     [PHP Database Programming]     [PHP SOAP]

  Powered by Linux