6 $page->title
= 'Stats and Stuff';
10 'today' => mktime(0, 0, 0),
11 'week' => mktime(0, 0, 0) - 86400*(gmdate('w')-1),
12 'month' => mktime(0, 0, 0, gmdate('m'), 1),
13 '24h' => (time()-86400),
14 '7d' => (time()-86400*7),
15 '30d' => (time()-86400*30)
23 foreach ($date as $num)
24 $return .= '<td>'.$DB->query(sprintf($sql, $num))->fetch_object()->result
.'</td> ';
30 <table id
="board_stats" style
="empty-cells: hide">
31 <caption
>Board Statistics
</caption
>
33 <colgroup title
="Row headers">
36 <colgroup title
="Fuzzy statistics">
39 <colgroup title
="Raw statistics">
40 <col
/><col
/><col
/><col
/>
49 <th
>Last
24 hours
</th
>
62 '<tr class="content c',(++
$a&1),'">
63 <th scope="row">Posts</th>
64 ',getrow('SELECT COUNT(*) AS `result` FROM `messages` WHERE `mtime` > %d'),'
65 <td>',$DB->query('SELECT COUNT(*) AS `result` FROM `messages`')->fetch_object()->result
,'</td>
68 <tr class="content c',(++
$a&1),'">
69 <th scope="row">Replies only</th>
70 ',getrow('SELECT COUNT(*) AS `result` FROM `messages` WHERE `replyto` IS NOT NULL AND `mtime` > %d'),'
71 <td>',$DB->query('SELECT COUNT(*) AS `result` FROM `messages`
72 WHERE `replyto` IS NOT NULL')->fetch_object()->result
,'</td>
75 <tr class="content c',(++
$a&1),'">
76 <th scope="row">Topics</th>
77 ',getrow('SELECT COUNT(DISTINCT(`topicid`)) AS `result` FROM `messages` WHERE `mtime` > %d'),'
78 <td>',$DB->query('SELECT COUNT(*) AS `result` FROM `topics`')->fetch_object()->result
,'</td>
81 <tr class="content c',(++
$a&1),'">
82 <th scope="row">Total users</th>
83 ',getrow('SELECT COUNT(*) AS `result` FROM `users` WHERE `register_date` > %d'),'
84 <td>',$DB->query('SELECT COUNT(*) AS `result` FROM `users`')->fetch_object()->result
,'</td>
87 <tr class="content c',(++
$a&1),'">
88 <th scope="row">Online users</th>
89 ',getrow('SELECT COUNT(`userid`) AS `result` FROM `users`
90 WHERE `last_active_date` > `register_date` AND `last_active_date` > %d'),'
91 <td>',$DB->query('SELECT COUNT(*) AS `result` FROM `users`
92 WHERE `last_active_date` > `register_date`')->fetch_object()->result
,'</td>
95 <tr class="content c',(++
$a&1),'">
96 <th scope="row">Active users</th>
97 ',getrow('SELECT COUNT(DISTINCT(`users`.`userid`)) AS `result` FROM `users`
98 NATURAL LEFT JOIN `messages`
99 WHERE `messages`.`mtime` > %d'),'
100 <td>',$DB->query('SELECT COUNT(DISTINCT(`users`.`userid`)) AS `result`
101 FROM `users` NATURAL LEFT JOIN `messages`')->fetch_object()->result ?
></td
>
107 <h2
>Terms of Service
</h2
>
109 <li
>Don
't be a fucking idiot.</li>
110 <li>Don't invite them
. Usermap axes are more aggressive here
.</li
>
111 <li
>This board is not AIM
. We
do not appreciate when people post here using leet
-speak
, shorthand (eg
. "plz", "u"),
112 sentences with no capitalization
, etc
. Typing in this manner makes you sound like a retarded high
-school dropout
,
113 and will only draw rude
/sarcastic replies
.</li
>