2018-06-20 21:19:13 +00:00
|
|
|
<?php $title="stats page";
|
|
|
|
$desc="stats about tilde.chat and its channels";
|
2018-10-15 22:29:34 +00:00
|
|
|
include __DIR__."/../header.php"; ?>
|
2018-06-20 21:19:13 +00:00
|
|
|
<h1>stats</h1>
|
|
|
|
<?php
|
2018-10-15 22:29:34 +00:00
|
|
|
$stats = json_decode(file_get_contents("../stats.json"));
|
2018-06-20 21:19:13 +00:00
|
|
|
?>
|
2018-07-19 14:44:08 +00:00
|
|
|
<p>There are <?=$stats->usercount?> users across <?=$stats->channelcount?> channels.</p>
|
2018-07-19 15:28:28 +00:00
|
|
|
<table class='table table-striped table-bordered table-hover'>
|
2018-07-19 14:44:08 +00:00
|
|
|
<thead><tr><th>Name</th><th>Users</th><th>Topic</th></tr></thead>
|
2018-07-19 15:28:28 +00:00
|
|
|
<tbody data-link="row" class="rowlink">
|
2018-07-19 14:44:08 +00:00
|
|
|
<?php foreach($stats->channels as $channel): ?>
|
2018-07-19 22:36:02 +00:00
|
|
|
<tr><td><a href="<?=$channel->webchatlink?>"><?=$channel->name?></a></td><td><?=$channel->usercount?></td><td><?=$channel->topic?></td></tr>
|
2018-07-19 14:44:08 +00:00
|
|
|
<?php endforeach; ?>
|
|
|
|
</tbody>
|
|
|
|
</table>
|
2018-06-20 21:19:13 +00:00
|
|
|
<hr>
|
2018-10-15 22:29:34 +00:00
|
|
|
<p>Available in <a href="/stats.json">JSON format</a>.</p>
|
|
|
|
<?php include __DIR__."/../footer.php"; ?>
|