teste.htm 1.08 KB
<html>
<head>
<title>Chart issue when using get-data to load json</title>




<script type="text/javascript" src="http://localhost/i3geo/ferramentas/graficointerativo/index.js.php"></script>

</head>

<body>

<script type="text/javascript">

</script>

<div id="testchart">test</div>

<script type="text/javascript">
function getDatatestchart()
{
    return JSON.stringify({ "elements": [ { "type": "bar_round_glass", "values": [ 518769, 135786, 168290, 463259, 167824, 701634, 709663, 425098, 513948, 575067 ] } ], "title": { "text": "Sat Jun 13 2009" }, "y_axis": { "min": 0, "max": 1000000, "steps": 100000 }, "num_decimals": 2, "is_fixed_num_decimals_forced": true, "is_decimal_separator_comma": true, "is_thousand_separator_disabled": true });
}

var so = new SWFObject("open-flash-chart.swf", "testchart", "600", "600", "9", "#ffffff");
so.addVariable("get-data", "getDatatestchart");
so.write("testchart");			

//swfobject.embedSWF("open-flash-chart.swf", "testchart", "350", "200", "9.0.0","",
//		{"get-data":"getDatatestchart"} );
</script>

</body>

</html>