2014-09-08 00:09:46 +02:00
|
|
|
<!DOCTYPE html>
|
|
|
|
<html>
|
|
|
|
<head>
|
|
|
|
<title>The Fall Invitational Leaderboard</title>
|
|
|
|
<meta http-equiv="refresh" content="30">
|
|
|
|
<link rel="stylesheet" href="https://maxcdn.bootstrapcdn.com/bootstrap/3.2.0/css/bootstrap.min.css">
|
|
|
|
<style type="text/css">
|
|
|
|
.table td.center, .table th.center {
|
|
|
|
text-align: center;
|
|
|
|
}
|
|
|
|
|
|
|
|
.panel-heading {
|
|
|
|
text-align: center;
|
|
|
|
font-size: 18pt;
|
|
|
|
font-weight: bold;
|
|
|
|
color: orange!important;
|
|
|
|
background-color: #333!important;
|
|
|
|
border-color: #333!important;
|
|
|
|
}
|
|
|
|
|
|
|
|
.panel-primary {
|
|
|
|
border-color: #333!important;
|
|
|
|
}
|
|
|
|
</style>
|
|
|
|
</head>
|
|
|
|
<body>
|
|
|
|
<div class="jumbotron" style="text-align: center">
|
|
|
|
<div class="container" style="text-align: center">
|
|
|
|
<img src="mineplex.png" alt="Mineplex"/>
|
2015-02-20 00:53:46 +01:00
|
|
|
<h1>The Tournament</h1>
|
|
|
|
<h2>Leaderboard</h2>
|
2014-09-08 00:09:46 +02:00
|
|
|
</div>
|
|
|
|
</div>
|
|
|
|
|
|
|
|
<hr/>
|
|
|
|
|
|
|
|
<div class="container-fluid">
|
|
|
|
<div class="row">
|
|
|
|
|
|
|
|
<?php
|
|
|
|
|
2015-02-20 00:53:46 +01:00
|
|
|
$tournamentTypes = array('Tournament');
|
2014-09-08 00:09:46 +02:00
|
|
|
|
|
|
|
$con = mysqli_connect('db.mineplex.com', 'root', 'tAbechAk3wR7tuTh', 'Account');
|
2015-02-20 00:53:46 +01:00
|
|
|
//$con = mysqli_connect('localhost', 'root', 'ZXquwQyEdKMB', 'Development');
|
2014-09-08 00:09:46 +02:00
|
|
|
|
|
|
|
for ($i = 0; $i < count($tournamentTypes); $i++)
|
|
|
|
{
|
|
|
|
?>
|
|
|
|
<div class="col-md-4">
|
|
|
|
<div class="panel panel-primary">
|
|
|
|
<div class="panel-heading"><?php echo $tournamentTypes[$i] ?></div>
|
|
|
|
<div class="table-responsive">
|
|
|
|
<table class="table">
|
|
|
|
<col style="width: 15%">
|
|
|
|
<col style="width: 40%">
|
|
|
|
<col style="width: 15%">
|
|
|
|
<col style="width: 15%">
|
|
|
|
<col style="width: 15%">
|
|
|
|
<tr>
|
|
|
|
<th class="center">Rank</th>
|
|
|
|
<th>Player</th>
|
|
|
|
<th class="center">Wins</th>
|
|
|
|
</tr>
|
|
|
|
<?php
|
2015-02-20 00:53:46 +01:00
|
|
|
|
|
|
|
$query = <<<QUERY
|
|
|
|
SELECT LB.rank, accounts.name, LB.value AS 'wins'
|
|
|
|
FROM TournamentLB LB
|
|
|
|
INNER JOIN accounts ON accounts.id = accountId
|
|
|
|
ORDER BY rank ASC
|
2014-09-16 00:47:49 +02:00
|
|
|
LIMIT 30;
|
2014-09-08 00:09:46 +02:00
|
|
|
QUERY;
|
2015-02-20 00:53:46 +01:00
|
|
|
|
2014-09-08 00:09:46 +02:00
|
|
|
$result = mysqli_query($con, $query);
|
|
|
|
|
|
|
|
$index = 1;
|
|
|
|
|
2015-02-20 00:53:46 +01:00
|
|
|
while($row = mysqli_fetch_array($result))
|
|
|
|
{
|
2014-09-08 00:09:46 +02:00
|
|
|
?>
|
|
|
|
<tr>
|
2015-02-20 00:53:46 +01:00
|
|
|
<td class="center"><?php echo $row['rank'] ?></td>
|
2014-09-08 00:09:46 +02:00
|
|
|
<td><?php echo $row['name'] ?></td>
|
|
|
|
<td class="center"><?php echo $row['wins'] ?></td>
|
|
|
|
</tr>
|
|
|
|
<?php
|
|
|
|
|
|
|
|
$index++;
|
|
|
|
}
|
|
|
|
|
|
|
|
?>
|
|
|
|
</table>
|
|
|
|
</div>
|
|
|
|
</div>
|
|
|
|
</div>
|
|
|
|
<?php
|
|
|
|
}
|
|
|
|
|
|
|
|
mysqli_close($con);
|
|
|
|
|
|
|
|
?>
|
|
|
|
</div>
|
|
|
|
</div>
|
|
|
|
<p style="text-align: center; font-style: italic">*Score = 100 × Wins × (Wins / Total)<sup>3</sup></p>
|
|
|
|
<hr/>
|
|
|
|
<script src="https://maxcdn.bootstrapcdn.com/bootstrap/3.2.0/js/bootstrap.min.js"></script>
|
|
|
|
</body>
|
|
|
|
</html>
|