PHP-GTK v2.0 - adding gd2

The default windows binary available from the official site does not include the gd2 library.

In case you need this library, you can get the libraries from Elizabeth Smith’s blog. (Note: she’s the one who compiled the windows binary in the official php-gtk site).

1. Goto http://perisama.net/downloads, navigate to “MSVC6″, then “PHP-5.2.5″, “Release”, and “ext”. You will see the file php_gd2.dll there.

2. Download the file and place it in the “ext” folder where you installed the php-gtk2.

3. In the php.ini file, add one more line

extension=php_gd2.dll

4. Now you have gd2 with php-gtk2!

For a quick test, you could try the following sample code:
Sample Code 232: How to draw a simple bar graph using GD2

/kksou

http://www.kksou.com/php-gtk2
The place for php-gtk2 sample codes

p.s. Thanks to Elizabeth Smith for sharing the above tips.

Leave a Reply