-
Notifications
You must be signed in to change notification settings - Fork 6
/
board.php
52 lines (48 loc) · 1.06 KB
/
board.php
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
<?php
//Author: Kadir CETINKAYA - breakv0id@0xdeffbeef
require_once("base.php");
if(isActive())
$active = "Active";
else
$active = "Frozen";
$left = getLeft();
$left = sprintf("%02d:%02d:%02d",(int)($left/3600), ($left/60)%60, $left%60);
?>
<div class="container">
<div class="panel panel-default">
<div class="panel-heading"><?=$board[0]?> [<?=$active?>: <?=$left?>]</div>
<table class="table">
<thead>
<tr>
<th>#</th>
<th><?=$board[1]?></th>
<th><?=$board[2]?></th>
</tr>
</thead>
<tbody>
<?php
$teams = (new Teams())->getTeams();
$id=0;
if($loggedin === true)
$id = $team->id;
foreach($teams as $cteam)
{
if($cteam->id===$id)
echo '<tr class="active">'."\n";
else
echo '<tr>'."\n";
?>
<td><?=$cteam->rank?></td>
<td><a href='/profile.php?id=<?=$cteam->id?>'><?=$cteam->name?></a></td>
<td><?=$cteam->score?></td>
</tr>
<?php
}
?>
</tbody>
</table>
</div>
</div>
<?php
require_once("footer.php");
?>