日期:2014-05-16  浏览次数:20400 次

open flash chart js画曲线图
<script type="text/javascript">
  var sof = new SWFObject("${ctx}/js/flashcharts/open-flash-chart.swf", "ofc", "500", "500", "9", "#FFFFFF");
  sof.addVariable("variables","true");
  sof.addVariable("title","一组,{font-size: 20;}");
  sof.addVariable("y_legend","时间,12,#736AFF");
  sof.addVariable("x_legend","天数,12,#736AFF");
  var str1="9,6,7,9,5,7,6,9,8";
  sof.addVariable("area_hollow","2,3,25,#CC3399,ID1,10");
  sof.addVariable("values",str1);
  sof.addVariable("x_labels","1day,2day,3day,4day,5day,6day,7day,8day,9day");
  sof.addVariable("x_axis_steps","2");
  sof.addVariable("y_max","10");//Y的最大数字
  sof.addVariable("y_ticks","5,10,10");
sof.addParam("allowScriptAccess", "sameDomain");
sof.write("my_chart");
</script>
这样就可以画个曲线图(如下图),怎么再增加条曲线啊??而且颜色要和原来的不一样,左上角的图例也随之增加,
在网站上的sof.addVariable("values_2",str2);加载代码里反而原来的曲线都不显示了,
哪个高手帮忙指点下???



------解决方案--------------------
再增加一个应该就可以了,
sof.addVariable("area_hollow_2","2,3,25,#CC3399,ID1,10");
sof.addVariable("values_2",str2);