Google introduced it Chart API last December.
For reference, I noted here my tips.
I need a 3D Pie chart. The code should looks like below:

<img src=”https://chart.apis.google.com/chart?cht=p3&chd=t:50,10,40&chs=500×200&chl=PR|HTTP Status|Whois”/>


The code can break down as shown here:
“cht=p3” is the chart type, in this case, a 3D pie chart.
“chd=t:50,10,40” are the chart values, text-encoded, and separated by a comma.
The number should be ranged from 0 to 100.
“chs=500×200” is the custom chart size, 500 by 200 pixels.
“chl=PR|HTTP Status|Whois” are the different labels for the pie chart sections, separated via the pipe character. Chinese is not supported by Chart API.
chart types include: line charts, bar charts, pie charts, Venn diagrams & scatterplots.

David Yin

David is a blogger, geek, and web developer — founder of FreeInOutBoard.com. If you like his post, you can say thank you here

Leave a Reply

Your email address will not be published. Required fields are marked *