Re: Strange Download-File Problem
| From: | Richard Lynch | Date: | Fri, 03 Dec 2004 18:01:47 +0000 |
| Subject: | Re: Strange Download-File Problem | ||
| References: | 1 2 | Groups: | php.general |
| Request: | Send a blank email to php-general+get-203444@lists.php.net to get a copy of this message | ||
Rahul S. Johari wrote:
href=\"imsafm2_download.php?F=imsafm/$showfilesuser/$myrow[filename]\"><img
> src=b_newtbl.png border=0></a>
One thing you might want to try...
I've noticed over the years that Microsoft will usually manage to screw up
if you've got a dynamic URL. I really don't understand (or care) why
Microsoft engineers are too stupid to handle dynamic content, but there it
is.
So you just get rid of anything in the URL that lets Microsoft screw up.
There are several articles/tutorials on the net how to use
$_SERVER['PATH_INFO'] and embed the file you want in the URL.
The goal here is to change the URL that looks like this:
imsafm2_download.php?F=imsafm/rahul/somefile.txt
into a URL that looks like this:
imsafm2_download/F=imsafm/rahul/somefile.txt
You'll also need to use .htaccess to force Apache to use PHP on
imsafm2_download (rename the file without the .php)
<Files imsafm2_download>
ForceType application/x-httpd-php
</Files>
The over-arching reason for doing all this, is to give Microsoft *NO*
opportunity to SCREW UP.
If the browser can't tell that it's not a plain old bring static file, it
can't screw it up.
You also need to do this for dynamic images, dynamid PDFs, FDFs, Ming
(Flash) files, and pretty much any other rich media content that you
generate dynamically.
--
Like Music?
http://l-i-e.com/artists.htm