本文整理汇总了PHP中Chart::getChart方法的典型用法代码示例。如果您正苦于以下问题:PHP Chart::getChart方法的具体用法?PHP Chart::getChart怎么用?PHP Chart::getChart使用的例子?那么恭喜您, 这里精选的方法代码示例或许可以为您提供帮助。您也可以进一步了解该方法所在类Chart
的用法示例。
在下文中一共展示了Chart::getChart方法的3个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的PHP代码示例。
示例1: Chart
}
?>
</table>
<?php
// if so show a timeline of player count
if ($g_options['showChart'] == "1") {
require 'class/chart.class.php';
$chartObj = new Chart($game);
$chart = $chartObj->getChart('playerActivity', $playersObj);
if (!empty($chart)) {
echo '<h2>', l('Players per day'), ' - ', l('Last'), ' ', $g_options['DELETEDAYS'], ' ', l('Days'), '</h2>';
echo '<div class="chart"><img src="', $chart, '" /></div>';
}
$chartObj2 = new Chart($game);
$chartObj2->setOption('height', 350);
$chart = $chartObj2->getChart('mostTimeOnline', $playersObj);
if (!empty($chart)) {
echo '<h2>', l('Most time online (hours)'), ' - ', l('Last'), ' ', $g_options['DELETEDAYS'], ' ', l('Days'), '</h2>';
echo '<div class="chart"><img src="', $chart, '" /></div>';
$chartData = $chartObj2->getChartData();
if (!empty($chartData)) {
echo '<h2></h2>';
echo "<ol>\n";
foreach ($chartData as $playerId => $entry) {
echo '<li><a href="index.php?mode=playerinfo&player=', $playerId, '">', makeSavePlayerName($entry['playerName']), '</a> ', getTimeFromSec($entry['timeSec']), '</li>';
}
echo "</ol>\n";
}
}
}
?>
示例2: l
echo l('Direct Link');
?>
" /></a>
(<?php
echo l('Last'), ' ', DELETEDAYS, ' ', l('Days');
?>
)
</h1>
<img src="<?php
echo $playtimeChart;
?>
" />
<?php
}
$chartObj = new Chart($game);
$killDayChart = $chartObj->getChart('killsPerDay', $player);
if (!empty($killDayChart)) {
?>
<a name="playerkillsperday"></a>
<h1>
<?php
echo l('Player Kill Statistics per Day');
?>
<a href="index.php?mode=playerinfo&player=<?php
echo $player;
?>
#playerkillsperday"><img src="hlstatsimg/link.gif" alt="<?php
echo l('Direct Link');
?>
" title="<?php
echo l('Direct Link');
示例3: l
}
} else {
echo "[1]";
}
echo '</td></tr>', "\n";
} else {
echo '<tr><td colspan="6">', l('No players recorded'), '</td></tr>', "\n";
}
?>
</table>
<?php
// if so show a timeline of player count
if ($g_options['showChart'] == "1") {
require 'class/chart.class.php';
$chartObj = new Chart($game);
$chart = $chartObj->getChart('playerActivity');
echo '<img src="', $chart, '" />';
/*
$chart = $chartObj->getChart('mostTimeOnline');
echo '<img src="',$chart,'" />';
// most time online
$query = mysql_query("SELECT ".DB_PREFIX."_Events_StatsmeTime.*,
TIME_TO_SEC(".DB_PREFIX."_Events_StatsmeTime.time) as tTime
FROM ".DB_PREFIX."_Events_StatsmeTime
LEFT JOIN ".DB_PREFIX."_Servers
ON ".DB_PREFIX."_Servers.serverId=".DB_PREFIX."_Events_StatsmeTime.serverId
WHERE ".DB_PREFIX."_Servers.game='".mysql_escape_string($game)."'");
while($result = mysql_fetch_assoc($query)) {
$onlineArr[$result['playerId']][] = $result;