root/dev/common/admin/admin_audit.php @ 207

Revision 207, 1.5 KB (checked in by ralle030583, 15 years ago)

- added system search
- added 12 new ship Signatures (thx to Arthur Ffrub)
- removed again some not needed includes

Line 
1<?php
2require_once('common/admin/admin_menu.php');
3
4$page = new Page('Administration - Audit log');
5$page->setAdmin();
6
7$sql = 'SELECT log_kll_id, log_ip_address, log_timestamp, kll_timestamp, plt_name
8                        FROM kb3_log log, kb3_kills kll, kb3_pilots plt
9                        WHERE log.log_kll_id = kll.kll_id
10                        AND plt.plt_id = kll_fb_plt_id
11                        ORDER BY log_timestamp DESC limit 250';
12
13$qry = new DBQuery();
14$qry->execute($sql) or die($qry->getErrorMsg());
15
16$html .= '<table class="kb-table">';
17$html .= "<tr class=kb-table-header><td align=center width=60>ID</td><td width=150>Killmail date</td><td width=150>Posted</td><td width=120>IP Address</td><td width=150>Final Blow</td></tr>";
18$odd = false;
19while ($row = $qry->getRow())
20{
21    if ($odd)
22    {
23        $class = "kb-table-row-even";
24        $odd = false;
25    }
26    else
27    {
28        $class = "kb-table-row-odd";
29        $odd = true;
30    }
31    $html .= "<tr class=" . $class . " onmouseover=\"this.className='kb-table-row-hover';\" onmouseout=\"this.className='" . $class . "';\" onClick=\"window.location.href='?a=kill_detail&kll_id=" . $row['log_kll_id'] . "';\">";
32    $html .= "<td align=center><b>" . $row['log_kll_id'] . "</b></td>";
33    $html .= "<td>" . $row['kll_timestamp'] . "</td>";
34    $html .= "<td>" . $row['log_timestamp'] . "</td>";
35    $html .= "<td>" . $row['log_ip_address'] . "</td>";
36    $html .= "<td>" . $row['plt_name'] . "</td>";
37    $html .= "</tr>";
38}
39$html .= "</table>";
40
41$page->addContext($menubox->generate());
42$page->setContent($html);
43$page->generate();
44
45?>
Note: See TracBrowser for help on using the browser.