note 45488 added to function.imagettftext
| From: | PaulReinheimer at osu1 dot php dot net | Date: | Thu, 09 Sep 2004 01:28:24 +0000 |
| Subject: | note 45488 added to function.imagettftext | ||
| Groups: | php.notes | ||
| Request: | Send a blank email to php-notes+get-76258@lists.php.net to get a copy of this message | ||
If you compiled PHP yourself (I'm running 5), but get a
Fatal error: Call to undefined function imagettftext().
error, you need to compile PHP with more options.
Specifically I ended up using:
./configure
--with-mysql=/usr/local/mysql
--with-apxs=/etc/httpd/bin/apxs
--with-gd
--enable-gd-native-ttf
--with-png
--with-zlib-dir=/usr/local/lib/zlib-1.2.1
--with-ttf
--with-jpeg-dir=/usr/local/lib/jpeg-6b/
--with-freetype-dir=/usr/local/lib/freetype-2.1.9/
--with-xpm-dir=/usr/X11R6/
Obviously (or not, depending on your experiance level) the MySQL option isn't required for
this, the apxs option will vary depending on your apache version and install location. The next set
deal with setting up GD, and the apropriate options. Just enabling GD, ttf, png & jpeg is NOT
enough. You also need Freetype and XPM. If you set all of that up, and end up with config errors
with regards to X11 you may also need the XFree86 development package (on an RPM based distro
up2date -i XFree86-devel should work wonders).
It would be awesome if the php manual included (or made it more obviously included if it is there
already) information on what options are needed at compile time for each function to work.
good luck
paul reinheimer (preinheimer.com)
----
Manual Page -- http://www.php.net/manual/en/function.imagettftext.php
Edit -- http://master.php.net/manage/user-notes.php?action=edit+45488
Delete -- http://master.php.net/manage/user-notes.php?action=delete+45488&report=yes
Reject -- http://master.php.net/manage/user-notes.php?action=reject+45488&report=yes
Search -- http://master.php.net/manage/user-notes.php