dynamic charts in php


ok I’ve been looking through the internet for nearly 2 weeks

but I found some things but they didn’t have a full tutorial and I’m really bad at php

so please if anyone can help me cause I’m really tired of looking for this

I want a chart that takes the data from my phpmyadmin table

the tables are called ‘x_axis’ and ‘y_axis’

in x_axis table the columns are called ‘id’ and ‘x_axis’

and in y_axis table the columns are called ‘id’ and ‘y_axis’

I want the x axis on the chart to take the data from the ‘x_axis’ column in the ‘x_axis’ table

and y axis on the chart to take the data from the ‘y_axis’ column in the ‘y_axis’ table

if your able to help me can you please explain to me how it works cause I really want to learn

thank you


Well that would depend on your graphing library you chose to use, their is no graphing library included with php


would you be able to direct me on what to do, which one is best to use



try google graphs there very simple to use


I would have to agree, if you dont mine yer site calling a third party website for the lib


Well, sorry guys, but, there are a TON of free charts apps out there that work with PHP.
Most use Javascript or JQuery to create the actual graphics. Some cost, but, a lot of them
are free. Here is one that would work…

NOTE: Click on the small link on the page for the actual info on downloading the libraries.

PS: In my opinion, EVERYTHING is possible. I have seen things that still make me say WOW!
This library is free and easy to use. Just make sure you read the docs! And, donate to them
if you use it so we can keep free software going… Good luck…


I never said there wasn’t.
I did say that google charts is easy to use, as long as you dont mind having a third party web call in your script.

a simple x,y chart is simple enough that you may consider building yer own, as long as you have gd lib enabled in php.

But Like I said, Google charts & graphs is an easy to use api and does decent work
Google Chart Tools


Yes, Laffin, Sorry, I meant to say, there are LOCAL apps that will do it for you WITHOUT using a third party that is loaded from another site. The one I posted can be used locally and you can customize it…
Sorry for the incorrect comment, Late here… LOL…


I know I made the graphs and they work but what i want is for the data to be taken from the phpmyadmin database

can anyone help me with that



Okay, so you mean you want to learn how to read a database and use the data inside it?
Or, do you mean you do not know how to send the data to your chart software?

If you mean reading a database, there are millions of tutorials for that. I think there are some in the tutorials section here on this site. Or, here is one that is a good one to start with: http://www.w3schools.com/php/php_mysql_intro.asp Press Next-Chapter to progress…

If you mean using your current data inside of MySQL database and putting it into a charting software,
that would depend on both what data you have now and which charting software you are using…