Re: Showing an image outside of the web folder

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

 



On 5/5/06, James Nunnerley <james@xxxxxxxxxxx> wrote:
Doing a "readfile ($file_location)" outputs the binary... can someone point
me in the direction of being able to translate that binary into a viewable
image file?

Drop the appropriate content-type header:

header('Content-type: image/png');
readfile('/home/foo/bar.png');

Rabin

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