This tutorial uses the deprecated mysql extension (as of PHP 5.5.0) which should not be used for writing new code as it will be removed in the future. The mysqli (MySQL Improved) or PDO extension should be used instead.

Nevertheless, it has been decided to keep this tutorial available until such time as it has been either updated or re-written. In the meantime, if you wish to take the tutorial, then it is recommended that you change the mysql-extension code to use mysqli or PDO. (If you do this successfully then perhaps you might consider submitting a revised tutorial, contributing to dream.in.code and earning some Kudos!)

There are times when a programmer needs a Dymanic image, or one that can change depending on the data given. For instance, Sales is one of them, Stocks are another, but any way you put it, Dynamic images are the way to go for a web designer.

Following this tutorial, you will create a very simple image with dynamic data. Now, Onto the tutorial!

the first part of this tutorial is about creating the image. Now, if you've Never used the GD library, I suggest you go and read the php.net page located here, but it is not necessary to understand this tutorial.

To start off, we will be creating a simple image like the one found here. Now, if you check the url, you will see that it end in ".php". This specific image gets the data from a database I have open and adds in the relevant data.