#21028 [Fbk->Bgs]: Call to undefined function: imagettfbbox()
| From: | sniper@php.net | Date: | Sun, 15 Dec 2002 22:10:44 +0000 |
| Subject: | #21028 [Fbk->Bgs]: Call to undefined function: imagettfbbox() | ||
| References: | 1 | Groups: | php.bugs |
| Request: | Send a blank email to php-bugs+get-27792@lists.php.net to get a copy of this message | ||
ID: 21028
Updated by: sniper@php.net
Reported By: webmaster@alnadabi.net
-Status: Feedback
+Status: Bogus
Bug Type: GD related
Operating System: redhat 7.3
PHP Version: 4.2.3
New Comment:
Sorry, but your problem does not imply a bug in PHP itself. For a
list of more appropriate places to ask for help using PHP, please
visit http://www.php.net/support.php as this bug system
is not the
appropriate forum for asking support questions.
Thank you for your interest in PHP.
Previous Comments:
------------------------------------------------------------------------
[2002-12-15 10:59:18] derick@php.net
Not enough information was provided for us to be able
to handle this bug. Please re-read the instructions at
http://bugs.php.net/how-to-report.php
If you can provide more information, feel free to add it
to this bug and change the status back to "Open".
Thank you for your interest in PHP.
------------------------------------------------------------------------
[2002-12-15 10:58:42] webmaster@alnadabi.net
I have already GD2 + Freetype2 installed in my machine
when i try to use the imagettfbbox() function , it's show that php
cannot fine the required library for that function !! however when i
used other image function , it's work fine with me ??
============ short script the reproduces the problem ======
<?php
$imagewidth = 100;
$imageheight = 20;
$fontsize = 12;
$myimg=ImageCreate($imagewidth, $imageheight);
$col1=ImageColorAllocate($myimg, 255, 0, 0);
$col2=ImageColorAllocate($myimg, 255, 255, 255);
$thetextbox = ImageTTFBBox ($fontsize, 0, "TIMES.TTF", "My Button");
$textwidth = (($thetextbox[4] + $thetextbox[2]) / 2) - (($thetextbox[6]
+ $thetextbox[0]) / 2);
$xpos = ($imagewidth - $textwidth) / 2;
$ypos = 14;
ImageTTFText ($myimg, $fontsize, 0, $xpos, $ypos, $col2,
"./ttfonts/arialnb.ttf", "My Button");
ImagePNG($myimg, "myimg.png");
ImageDestroy($myimg);
?>
<img src="myimg.png" border=0>
================================================
any suggestions ??
Regards,
AlNadabi
------------------------------------------------------------------------
--
Edit this bug report at http://bugs.php.net/?id=21028&edit=1