How to Install PHP GD Support to Apache on Ubuntu
GD library is used to create and manipulate image files in PHP. PHP will need to be compiled with the GD library for image functions to work. If you are using Apache web server and want to install PHP GD support, then this tutorial will help you a lot. Ubuntu comes with the package called php5-gd to add GD support. You need to install php5-gd to Apache for using the image functions in PHP.
Just follow the below simple steps to enable the GD extension under Ubuntu 14.04.
Open the Terminal and type the following command.
sudo apt-get install php5-gd
Once the php5-gd installation is complete, restart the Apache 2 web server by entering the following command.
sudo service apache2 restart
Now verify whether PHP GD Support is enabled or not.
php -i | grep -i --color gd
You’ll see the output below.
/etc/php5/cli/conf.d/20-gd.ini,
gd
GD Support => enabled
GD Version => 2.1.1-dev
gd.jpeg_ignore_warning => 0 => 0
GDM_LANG => en_US
GDMSESSION => ubuntu
_SERVER["GDM_LANG"] => en_US
_SERVER["GDMSESSION"] => ubuntu
You can also check the GD extension status using PHP script. Create a file (test.php
) => place the following code in this file (test.php
) => Run this file (test.php
) and look for a GD extension.
<?php
phpinfo();
?>
0 Comments
CAN FEEDBACK
Emoji