Reputation: 25369
Anyone know if there is a PHP wrapper for the latest version (5.X) of XML/SWF charts
Upvotes: 1
Views: 1435
Reputation: 241
As part of another project, I developed an open-source CodeIgniter library for generating the XML required by XML/SWF Charts: http://milktek.com/XML-SWF-Charts-for-CI
However, looking over the code in this library, I believe it will work outside of CodeIgniter as well. Just create a new Maani_xml_swf_charts
object and call the various available methods. It should work because there is no CodeIgniter dependent code in the library.
$mxsc = new Maani_xml_swf_charts();
$mxsc->chart_type("stacked column");
$mxsc->chart_data(
array("sales","non-sales"),
array("Clothing","Food","Toys"),
array(
array("100","145"),
array("34","54"),
array("84","21")));
$mxsc->chart_label(array(
"shadow"=>'low',
"color"=>'ffffff',
"alpha"=>'95',
"size"=>'20',
"position"=>'inside',
"as_percentage"=>'true'));
Upvotes: 1
Reputation: 1
I don't know about the XML/SWF charts software, but if you feel like hand coding it, you can use PHP's XML classes and Ming to dynamically create charts. You would simply parse the xml data from the file, and pass it to a Ming object for processing. then include the swf when done.
Simple!
;-)
Upvotes: 0
Reputation: 134711
http://www.maani.us/charts/index.php
"As of version 5.0, there isn't a dedicated PHP interface for this charts tool. However, PHP or any other scripting language can still be used with XML/SWF Charts (the XML version of the same tool)."
There are examples how to use XML version with PHP:
http://www.maani.us/xml_charts/index.php?menu=Reference&submenu=Scripting
Upvotes: 1