Requirement
- web browser with Flash Player 9 or later
- XML/SWF Charts
Installation
- Download XML/SWF Charts, extract the download package, and put somewhere on your web server. I put mine into folder charts.
- Open your browser, and go to http://localhost/charts/sample.html
That’s it. You’ll see a charts in your browser.
If you want to feed data to the chart or you want to visualize your data with with XML/SWF Charts. Open sample.xml and write your XML. Just say you want to put this data into XML/SWF Charts.
| 2001 | 2002 | 2003 | |
|---|---|---|---|
| Company A | 100000 | 200000 | 150000 |
| Company B | 98000 | 100000 | 160000 |
| Company C | 200000 | 210000 | 180000 |
So here your sample.xml should look like :
1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 | <?xml version="1.0"?> <chart> <chart_data> <row> <null/> <string>2001</string> <string>2002</string> <string>2003</string> </row> <row> <string>A</string> <number>100000</number> <number>200000</number> <number>150000</number> </row> <row> <string>B</string> <number>98000</number> <number>100000</number> <number>160000</number> </row> <row> <string>C</string> <number>200000</number> <number>210000</number> <number>180000</number> </row> </chart_data> </chart> |
That’s it. You can fire up your browser again, and see the result at http://localhost/charts/
Related posts:
- CakePHP Tutorial:Installing CakePHP on Ubuntu
- Showing the weather with PHP and Google Weather API
- How to Force Browser to Download PDF File
- CodeIgniter Tutorials to Help You Get Started
- Codeigniter tutorial – To do list application
Tags: PHP