#1 (permalink)  
Old 07-10-2009, 04:09 PM
Registered User
 
Join Date: Jun 2009
Posts: 30
ronaldoo is on a distinguished road
PHP GD Library

Hello friends,
Anyone can tell me how can I enable or install the GD Library of PHP?
Thanks all!
Digg this Post!Add Post to del.icio.usBookmark Post in TechnoratiFurl this Post!
Reply With Quote
  #2 (permalink)  
Old 07-10-2009, 04:14 PM
cPanelDavidG's Avatar
cPanel Technical Sales
 
Join Date: Nov 2006
Location: Houston, TX
Posts: 7,995
cPanelDavidG is on a distinguished road
Quote:
Originally Posted by ronaldoo View Post
Hello friends,
Anyone can tell me how can I enable or install the GD Library of PHP?
Thanks all!
You will need root access to the server to do this.

1. Go to WHM -> Software -> EasyApache
2. proceed through to step 5 of EasyApache
3. Click on Exhaustive Options List
4. Check the box for GD
5. Save & Build.
__________________
Want our technical analysts to login to your server to assist you? You can contact our technical analysts at: http://tickets.cPanel.net/submit
Digg this Post!Add Post to del.icio.usBookmark Post in TechnoratiFurl this Post!
Reply With Quote
  #3 (permalink)  
Old 07-20-2009, 06:02 PM
Registered User
 
Join Date: Jun 2009
Posts: 30
ronaldoo is on a distinguished road
Was solved, thank you!
Digg this Post!Add Post to del.icio.usBookmark Post in TechnoratiFurl this Post!
Reply With Quote
  #4 (permalink)  
Old 07-22-2009, 02:11 AM
Registered User
 
Join Date: Jul 2009
Posts: 57
Janak is on a distinguished road
There is also an another way to enable GD.

You can also do it from SSH. Run easyapache script and then go to Exhaustive Options List and select GD.
Digg this Post!Add Post to del.icio.usBookmark Post in TechnoratiFurl this Post!
Reply With Quote
  #5 (permalink)  
Old 07-22-2009, 09:55 AM
Registered User
 
Join Date: Jun 2009
Posts: 30
ronaldoo is on a distinguished road
Quote:
Originally Posted by Janak View Post
There is also an another way to enable GD.

You can also do it from SSH. Run easyapache script and then go to Exhaustive Options List and select GD.
Ok, thanks!
Digg this Post!Add Post to del.icio.usBookmark Post in TechnoratiFurl this Post!
Reply With Quote
  #6 (permalink)  
Old 07-22-2009, 05:05 PM
Spiral's Avatar
Registered User
 
Join Date: Jun 2005
Location: Area 51
Posts: 1,501
Spiral is on a distinguished road
Thumbs up

And there is another way ...

If you want GD to really work 100% ...

Compile PHP manually!

(Actually there is reason for this if you are wanting full GD and have all the functions and components actually work correctly)

Open a phpinfo() screen to get your current ./configure options as you'll need the rest of your options later below as !!!OPTIONS!!!

Code:
# yum install coreutils make gcc* glib* libexif libjpeg* libpng* giflib* gd gd-* netpbm Image* freetype*
# /scripts/checkperlmodules    (might want to do this 2 or three times)
At this point you should have an updated compile environment along with the main libraries you will need to build a good GD environment.

Code:
# cd /usr/local/src
# wget http://us3.php.net/get/php-5.2.10.tar.bz2/from/us2.php.net/mirror
# tar jxvf ./php-5.2.10.tar.bz2
# cd php-5.2.10
# ./configure --with-zlib --with-zlib-dir=/usr --with-jpeg-dir=/usr --with-png-dir=/usr --with-freetype-dir=/usr --enable-gd-native-ttf --with-ttf --with-exif --with-gd --with-imagick  !!!YOUR OTHER OPTIONS!!!

(Note the order of the options I've shown --- That is important!)

# make
# make test
# make install
Depending on whether you are using DSO or SuPHP based PHP per the rest of your configure options taken from your current PHP installation, you may or may not need to go update httpd.conf or /opt/suphp/etc/suphp.conf.

Restart your apache server
Code:
service httpd restart
You should now have a well working GD2 system if all went well.

The pre-requisite yum installer I gave you also asked to install ImageMagick which is another very powerful graphics package that a lot of PHP scripts like to use. There is an optional module you can add to PHP to give you direct ImageMagick functions from within PHP.

Code:
# cd /usr/local/src/php-5.2.10/ext
# wget http://pecl.php.net/get/imagick-2.3.0RC2.tgz
# tar zxvf ./imagick-2.3.0RC2.tgz
# mv imagick-2.3.0 imagick
# cd imagick
# phpize
# ./configure 
# make
# make test
# make install
You should now have a line in your /usr/local/lib/php.ini file to load the extension that looks like the following:

Code:
extension=imagick.so
Alternatively you could do everything up to the "phpize" command above after you unpacked your original php-5.2.10.tar.bz2 archive but before you compiled PHP and then added "--with-imagick" to the end of the original GD configure options when you compiled PHP and you will have the optional ImageMagick support (imagick) add-on module hard compiled directly into PHP itself instead of being loaded as an external extension module.
Digg this Post!Add Post to del.icio.usBookmark Post in TechnoratiFurl this Post!
Reply With Quote
Reply

Thread Tools
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are On


Similar Threads
Thread Thread Starter Forum Replies Last Post
Problem with PHP library mysqli.so helenamunoz cPanel and WHM Discussions 2 05-05-2009 03:07 PM
install php library khanhtran cPanel and WHM Discussions 1 04-07-2008 03:30 AM
PHP GD Library AnthonyCaesar cPanel and WHM Discussions 3 03-22-2005 08:18 PM
How can I upgrade the php GD library from 2.0.23 to 2.0.28? AbeFroman cPanel and WHM Discussions 18 09-24-2004 05:54 PM


All times are GMT -5. The time now is 02:25 PM.


Powered by vBulletin® Version 3.8.2
Copyright ©2000 - 2009, Jelsoft Enterprises Ltd.
© cPanel Inc