当前位置: 首页>>代码示例>>PHP>>正文


PHP Chart::getChart方法代码示例

本文整理汇总了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&amp;player=', $playerId, '">', makeSavePlayerName($entry['playerName']), '</a> ', getTimeFromSec($entry['timeSec']), '</li>';
            }
            echo "</ol>\n";
        }
    }
}
?>
开发者ID:beporter,项目名称:hlstats,代码行数:31,代码来源:players.inc.php

示例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&amp;player=<?php 
        echo $player;
        ?>
#playerkillsperday"><img src="hlstatsimg/link.gif" alt="<?php 
        echo l('Direct Link');
        ?>
" title="<?php 
        echo l('Direct Link');
开发者ID:BlackMajic,项目名称:HLStats,代码行数:31,代码来源:playerinfo.inc.php

示例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;
开发者ID:BlackMajic,项目名称:HLStats,代码行数:31,代码来源:players.inc.php


注:本文中的Chart::getChart方法示例由纯净天空整理自Github/MSDocs等开源代码及文档管理平台,相关代码片段筛选自各路编程大神贡献的开源项目,源码版权归原作者所有,传播和使用请参考对应项目的License;未经允许,请勿转载。