Re: imagestring to picture

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

 



On Mon, August 22, 2005 12:45 am, Andras Kende wrote:
> I have a some colorful pictures, Would like to add white text with
> black
> background around the white text...
>
> I can add the text fine but could figure out how to add black
> background..
>
>
> $textcolor = imagecolorallocate($destimg, 255, 255, 255);

$black = imagecolorallocate($destimg, 0, 0, 0);
imagefilledrectangle($destimg, 8, 8, 8 + 5 * strlen("test text"), 13,
$black);

> imagestring($destimg, 3, 10, 10, "test text", $textcolor);
> imagejpeg($destimg);

-- 
Like Music?
http://l-i-e.com/artists.htm

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