Difference between revisions of "How to Install GD for PHP on CentOS 6"
From Acenet Knowledgebase
Docs admin (Talk | contribs) |
Docs admin (Talk | contribs) |
||
(One intermediate revision by the same user not shown) | |||
Line 24: | Line 24: | ||
gd | gd | ||
</syntaxhighlight> | </syntaxhighlight> | ||
+ | |||
+ | [[Category: CentOS 6]] [[Category: PHP]] |
Latest revision as of 23:11, 11 January 2013
GD is a graphics library available for PHP. It gives PHP the ability to create GIF, PNG, JPEG, WBMP, and XPM image formats. GD can even output image streams directly to a browser. On CentOS 6, GD is available as an RPM and can easily be installed with yum.
Installing GD
To install GD on CentOS 6, simply run:
yum install gd-php
Restart your Web Server
After installing GD, restart your web server. Assuming you're running Apache, you can run:
/etc/init.d/httpd restart
Confirm GD is Installed
You can list available PHP modules to confirm GD was successfully installed:
php -m | grep -i gd
Here's example output showing GD has been installed:
[root@vps ~]# php -m | grep -i gd
gd