Exemplo n.º 1
0
    ?>
                <div class="col-lg-<?php 
    echo $gridsize;
    ?>
 col-md-6">
                    <div class="panel panel-yellow">
					
						<?php 
    $query = $link->query("SELECT SUM(`points`) FROM `ranks` WHERE `points` > 0");
    $array2 = mysqli_fetch_array($query);
    $total_points = $array2[0];
    $total_points = unitFormat($total_points, $decimals = 2);
    $query = $link->query("SELECT AVG(`points`) FROM `ranks` WHERE `points` > 100");
    $array2 = mysqli_fetch_array($query);
    $avg_points = $array2[0];
    $avg_points = unitFormat($avg_points, $decimals = 0);
    ?>
					
                        <div class="panel-heading">
                            <div class="row">
                                <div class="col-xs-12 text-center">
                                    <div class="huge">Points</div>
                                </div>
                                <div class="col-xs-6 text-left">
                                    <div class="huge"><?php 
    echo $total_points;
    ?>
</div>
                                </div>
                                <div class="col-xs-6 text-right">
                                    <div class="huge">~<?php 
Exemplo n.º 2
0
		<div class="panel panel-yellow">
			<div class="panel-footer">
				</center>Points Ranking</center>
				<div class="clearfix"></div>
			</div>
			<div class="panel-heading">
				<div class="row">
					<div class="col-xs-12 text-center">
						<div class="huge"><?php 
    echo $chatrank;
    ?>
</div>
					</div>
					<div class="col-xs-4 text-left">
						<div class="huge"><?php 
    echo unitFormat($points);
    ?>
</div>
					</div>
					<div class="col-xs-4 text-center">
						<div>Chatrank</div>
					</div>
					<div class="col-xs-4 text-right">
						<div class="huge">#<?php 
    echo $rank;
    ?>
</div>
					</div>
					<div class="col-xs-6 text-left">
						<div>Points</div>
					</div>
Exemplo n.º 3
0
$sql = "SELECT `points`, `lastname`, `auth`, `lastplay` FROM `ranks` ORDER BY `points` DESC LIMIT 25";
$players = $link->query($sql);
$rank = 0;
while ($array = mysqli_fetch_array($players)) {
    $rank++;
    $lastplay = $array["lastplay"];
    $timestamp = gmdate("Y-m-d\\ H:i:s", $lastplay);
    $steamfix = $array[2];
    if ($steamfix[6] == '0') {
        $steamfix[6] = '1';
    } else {
        $steamfix[6] = '0';
    }
    $query = $link->query("SELECT AVG(`rank`) FROM `round` WHERE `auth` = \"" . $steamfix . "\"");
    $array2 = mysqli_fetch_array($query);
    $count_avgrank = unitFormat($array2[0]);
    $query = $link->query("SELECT COUNT(*) FROM `round` WHERE `rank` = 1 AND `auth` = \"" . $steamfix . "\"");
    $array2 = mysqli_fetch_array($query);
    $count_wrs = $array2[0];
    $query = $link->query("SELECT COUNT(*) FROM `round` WHERE `auth` = \"" . $steamfix . "\"");
    $array2 = mysqli_fetch_array($query);
    $count_records = $array2[0];
    $query = $link->query("SELECT SUM(`finishcount`) FROM `round` WHERE `auth` = \"" . $steamfix . "\"");
    $array2 = mysqli_fetch_array($query);
    $count_finishcount = $array2[0];
    echo "<tr class=\"odd gradeX\">\n\t\t\t\t\t\t\t\t<td>" . $rank . "</td>\n\t\t\t\t\t\t\t\t<td><a href='index.php?site=player&auth=" . $array[2] . "'>" . $array[1] . "</a></td>\n\t\t\t\t\t\t\t\t<td>" . getChatRank($rank, $chattag_list) . "</td>\n\t\t\t\t\t\t\t\t<td>" . $array[0] . "</td>\n\t\t\t\t\t\t\t\t<td>" . $count_avgrank . "</td>\n\t\t\t\t\t\t\t\t<td>" . $count_wrs . "</td>\n\t\t\t\t\t\t\t\t<td>" . $count_records . "</td>\n\t\t\t\t\t\t\t\t<td>" . $count_finishcount . "</td>\n\t\t\t\t\t\t\t\t<td>" . $timestamp . "</td>\n\t\t\t\t\t\t\t</tr>";
}
?>
						</tbody>
					</table>
				</div>