Outputing text with an image

From: Date: Wed, 12 Mar 2003 04:59:21 +0000
Subject: Outputing text with an image
Groups: php.windows 
Request: Send a blank email to php-windows+get-18979@lists.php.net to get a copy of this message
How can I incorporate the text - "This is a square" - under the .jpg file? The following php script outputs the reduced square but no copy. Thank you. Tony Ritter .......................................................... <? $new_w=50; $new_h=50; header("Content-type: image/png"); header("Content-type: text/html"); $dst_img=ImageCreate($new_w,$new_h); $src_img=ImageCreateFromPng("./square.png"); ImageCopyResized($dst_img,$src_img,0,0,0,0,$new_w,$new_h,ImageSX($src_img),I mageSY($src_img)); ImagePng($dst_img); echo "This is a square."; // This line does not print on output ?>

« previous php.windows (#18979) next »