#20129 [Opn->Bgs]: ImageTTFText & implode(" ", "$argv")

From: Date: Mon, 28 Oct 2002 04:07:41 +0000
Subject: #20129 [Opn->Bgs]: ImageTTFText & implode(" ", "$argv")
References: 1  Groups: php.bugs 
Request: Send a blank email to php-bugs+get-23523@lists.php.net to get a copy of this message
ID: 20129 Updated by: sterling@php.net Reported By: jbw@justinw.net -Status: Open +Status: Bogus Bug Type: GD related Operating System: Linux 2.x PHP Version: 4.2.3 New Comment: ohhh, god... Previous Comments: ------------------------------------------------------------------------ [2002-10-27 20:48:08] jbw@justinw.net I cannot use implode with the ImageTTFText function. The following code does not work, it returns a broken image: <?php Header("Content-type: image/png"); //$string = "Test"; $string = implode(" ", "$argv"); $string = urldecode($string); $im = imageCreateFromPng("header_img2.png"); $white = ImageColorAllocate($im, 167, 194, 206); $px = (imagesx($im)-7.5*strlen($string))/2; ImageTTFText($im, 30, 0, $px, 42, $white, "/usr/local/apache/htdocs/ttf/ARTBRUSH.TTF", "$string"); ImagePng($im); ImageDestroy($im); ?> If I comment out the implode line and set $string then it works great. I use implode with other code for creating other images but not with ImageTTFText. Thanks! - Justin ------------------------------------------------------------------------ -- Edit this bug report at http://bugs.php.net/?id=20129&edit=1

« previous php.bugs (#23523) next »