本文整理汇总了PHP中FusionCharts::setRenderer方法的典型用法代码示例。如果您正苦于以下问题:PHP FusionCharts::setRenderer方法的具体用法?PHP FusionCharts::setRenderer怎么用?PHP FusionCharts::setRenderer使用的例子?那么恭喜您, 这里精选的方法代码示例或许可以为您提供帮助。您也可以进一步了解该方法所在类FusionCharts
的用法示例。
在下文中一共展示了FusionCharts::setRenderer方法的1个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的PHP代码示例。
示例1: FusionCharts
<div id="content-area-inner-main">
<h2 class="headline"> Simple Column 3D Chart </h2>
<div class="gen-chart-render">
<CENTER>
<p> </p>
<?php
//This page demonstrates the ease of generating charts using FusionCharts PHPClass.
//For this chart, we've cread a chart object used FusionCharts PHP Class
//supply chart data and configurations to it and render chart using the instance
//Here, we've kept this example very simple.
# Create column 3d chart object
$FC = new FusionCharts("Column3D", "600", "300");
# Set JavaScript renderer
$FC->setRenderer("javascript");
# Set Relative Path of swf file.
$FC->setSWFPath("../../FusionCharts/");
# Define chart attributes
$strParam = "caption=Monthly Unit Sales;xAxisName=Month;yAxisName=Units";
# Set Chart attributes
$FC->setChartParams($strParam);
#add chart data values and category names
$FC->addChartData("462", "Label=Jan");
$FC->addChartData("857", "Label=Feb");
$FC->addChartData("671", "Label=Mar");
$FC->addChartData("494", "Label=Apr");
$FC->addChartData("761", "Label=May");
$FC->addChartData("960", "Label=Jun");
$FC->addChartData("629", "Label=Jul");
$FC->addChartData("622", "Label=Aug");