|
Posted by Richard Lynch on 05/14/05 06:16
On Fri, May 13, 2005 3:45 pm, Chris Bruce said:
>> header("Content-type: image/jpg");
>> Header('Content-Disposition: attachment;
>> file="tigershippingdashboard20050429.jpg"');
>> echo $ret;
>
> Did you try this Jason? When I try it, it just downloads the
> getimage.php file with the binary content of the image in the file.
Content-Disposition only works on some browsers.
The ONLY way to get EVERY browser to behave is to make your URL end in
tigershippingdashboard20050429.jpg -- and ideally to not have any other
extension (.php or .htm or .html or .shtml or ...) in the URL and also, if
you want it to work for various other multi-media (PDF, SWF, etc) you
might as well set up to use $_SERVER['PATH_INFO'] instead of $_GET
Whew. That was my rant boiled down to one run-on sentence. :-)
HOW to do all that is in the archives with my name and PATH_INFO on it
most recently, though I really just stole all the bits and pieces from
everybody else.
--
Like Music?
http://l-i-e.com/artists.htm
[Back to original message]
|