Re: cURL functions

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

 



On Thu, May 12, 2005 11:54 am, Chris Bruce said:
> API. The problem is that the resulting image is being displayed as
> binary characters in the browser instead of downloading to my computer.

> Does anyone know how I can take the binary result and force it to
> download as a JPG image?

At a minimum, for current browsers, you need:
header("Content-type: image/jpeg");
before you send the JPEG out.

Actually, before you send *ANYTHING* out, but you'd break the JPEG sending
anything else out before that anyway.

If you want to support older browsers, on more platforms, you would do
well to look at another thread from yesterday where I talk about about
PATH_INFO.

-- 
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