JPowered.com

Graph and Chart Software Documentation

 

Upgrade GD

 

How to enable GD for a Linux / UNIX PHP installation

Since PHP 4.3 the GD environment has been built into the Linux / UNIX installation. As such the easiest way to install GD is to upgrade the PHP version to at least 4.3. For the latest PHP downloads please see:-
http://www.php.net/downloads.php

However if you do not wish to upgrade your version of PHP then the GD Library can be installed itself.

The first step is download the latest tar.gz file from:-

http://www.libgd.org

Next extract the package and you should see the index.html document. Follow the instructions in this document to install GD on your system.

Once the GD library has been successfully built then you will probably have to restart your server in order for PHP to pick it up.

More References
PHP Manual - Setting Up GD »

 

How to enable GD for a Windows PHP installation

The first thing to check is that you have the GD dll on your system

Look in the directory "./ext" where you have installed PHP. In this directory you should see a file "php_gd2.dll" ( or "php_gd.dll"). If the file is there then you have the GD module, if not then you will need to obtain this DLL ( see below » )

The next thing to do is look in your php.ini file for the line,

extension=php_gd2.dll
( or extension=php_gd.dll )

If this is commented out (ie with a semicolon in front of it) then uncomment it and save the php.ini file.

You may also need to modify the directive "extension_dir". This directive tells PHP where to find the dlls for the modules, eg,

extension_dir = "c:/php/ext/"

Stop Web Server and then restart.

That should be all there is to it. Now when you run the phpinfo command you should see the GD section in the list.

How to Obtain the php_gd2.dll

The GD DLLs are provided in the latest download packages of the PHP installation for windows.

Download the zip package for Windows from the following page:-
http://www.php.net/downloads.php

Unzip the package and copy the php_gd2.dll from the ./ext/ dir to the /ext/ dir of your installation.
( In some cases it is also necessary to place a copy of all the DLLs in the ./ext/ dir in the ./system32 dir. )


More References
PHP Manual - Setting Up GD »

 

 

Documentation

Demo Index

Troubleshooting Guide

Support

Documentation Contents

Adding Graphs to Web Pages

Configuration Options and Parameters

Supplying the Graph with Data

Sample Image Tags

Database Connections

Database Information method

Custom Data Function

Installation Help

Upgrade PHP

Upgrade GD

Log File

Allow URL Fopen