[PHP] Re: imagettftext color problem

2005-02-11 Thread Anni Hienola
And to correct one mistake in the code that was kindly pointed out but is here just a typo: > $bg=imagecolorallocate($img, 255, 255, 255); > $font_color=imageallocatecolor($img, 0, 0, 0); Should be: $bg=imagecolorallocate($img, 255, 255, 255); $font_color=imagecolorallocate($img, 0, 0, 0); Full

[PHP] imagettftext color problem

2005-02-10 Thread Anni Hienola
Hello, I want to display TTF text in a png image. I use the following type of code: $font="luxisr"; $font_size=16; $img=imagecreate($width, $height); $bg=imagecolorallocate($img, 255, 255, 255); $font_color=imageallocatecolor($img, 0, 0, 0); imagettftext($img, $font_size, 0, $x, $y, $font_color,