Thread: GD problem
View Single Post

  #2 (permalink)  
Old 09-23-2003
Pete James
 
Posts: n/a
Default Re: [PHP] GD problem

You're outputting a blank PNG image, in binary form. In order to
display it (not that you'd see anything since it's blank), you need to
output a Content-Type header first, like so:

header("Content-Type: image/png");

THis will instruct the browser to treat the incoming data as image data.

HTH.

Ignacio Correa wrote:

> Hi, I´m new in PHP+GD.
> I have install all library (PHP4-gd2, libgd2, etc, etc, etc.) and when I use gd functions no errors or warning are displayed, but when I use imagepng() or imagejpeg() no images are displayed in my browser, and in this place extrage symbols are displayed.
> You can see my bad result here: http://www.drivingconsultancy.com/ide/testi.php
>
> If somebody can helpme, I´ll be very thanks
>
> (sorry, my eglish isn´t good, I´m from Argentine)

Reply With Quote