Re: ImageTTFText question

From: Date: Tue, 18 Jul 2000 18:20:04 +0000
Subject: Re: ImageTTFText question
References: 1  Groups: php.general 
Request: Send a blank email to php-general+get-7117@lists.php.net to get a copy of this message
Take the Header() part out....and when you get to the ImageGif ($im); part, change it to ImageGif ($im, $image_filename); where $image_file name is the name of the file you would like to be saved to. Then echo an <img src="$image_filename"> where you want the image to show up...hope that helps and you can understand it. ----- Original Message ----- From: "Eric Wood" <eric@interplas.com> To: <php-general@lists.php.net> Sent: Tuesday, July 18, 2000 1:12 PM Subject: [PHP] ImageTTFText question > I can get an example like this to work: > > <?php > Header ("Content-type: image/gif"); > $im = imagecreate (400, 30); > $black = ImageColorAllocate ($im, 0, 0, 0); > $white = ImageColorAllocate ($im, 255, 255, 255); > ImageTTFText ($im, 20, 0, 10, 20, $white, "/path/arial.ttf", > "Testing... Omega: &#937;"); > ImageGif ($im); > ImageDestroy ($im); > ?> > > but when I want to put the image in the middle of a page somewhere I get a > garbage.. it's like the Content-type: image/gif is absolutely needed. So > how can I use this function after the header has already been sent? > > -Eric Wood > > > > -- > PHP General Mailing List (http://www.php.net/) > To unsubscribe, e-mail: php-general-unsubscribe@lists.php.net > For additional commands, e-mail: php-general-help@lists.php.net > To contact the list administrators, e-mail: php-list-admin@lists.php.net >

« previous php.general (#7117) next »