Re: [GD] Image errors

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

 



Martin Scotta wrote:
> Why are you ussing GD?
> All you need is output the image to the browser?
> 
> try this... I didn't test/run this code, but it may work...
> 
> public function showPicture( $id ) {
>       header('Content-type:' . mime_content_type( $this->updir . $id .
> '.png' ) );
>       readfile( $this->updir . $id . '.png' );
>   }
> 
> hey, look, just 2 lines!
> 
But it doesn't convert the image from whatever came in to a JPEG output, which
is what the OP's code appears to be trying to do (and possibly ought to work...)



-- 
Peter Ford                              phone: 01580 893333
Developer                               fax:   01580 893399
Justcroft International Ltd., Staplehurst, Kent

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