PHP Bargraph Generator

Article published Wednesday, September 16th, 2009 at 11:36 am

This script is loaded using an image tag and generates data based on information added as GET parameters.

For example:

<img src="bar.php?value=100&max=256&info" />

Generates:

This script requires at least four files to use. The first is an HTML file which loads the image (of course), the second is the background “bar.png” image which the graph is built on, the third is a ttf font file, and the fourth is the bar.php script which does all the work. You can see the latter on this page, or you can click the link below to download all the files.

Download PHP Bargraph Generator

Advanced Preview

CodeVault Entry

Tags: ,

Category: PHP Tutorials

We don't only write awesome web development tutorials, we also build awesome web software! Check out NeoInvoice, a time tracking, issue ticket, invoice making web app! It's 100% free for our readers!

2 Responses to “PHP Bargraph Generator”

  1. Hi Guys, if anyone is still updating this script, please could you help me add a comma as a thousand separator into the text out put for large numbers, for example 10,000/20,000 (50%).

    Thanks for a great script.

    Stuart

Leave a Reply