Table UI fixes

This commit is contained in:
Arjit Chaudhary
2015-09-23 15:48:53 +05:30
parent 20adc269ac
commit d055902487

View File

@@ -2,8 +2,8 @@
echo "<h3>Authlog</h3>"; echo "<h3>Authlog</h3>";
echo "<hr>"; echo "<hr>";
if ($_SESSION['userlevel'] >= '10') { if ($_SESSION['userlevel'] >= '10') {
echo '<table cellspacing=0 cellpadding=1 width=100%>'; echo '<table class="table table-hover table-condensed">';
echo "<th>Timestamp</th><th>User</th><th>IP Address</th><th>Result</th>";
foreach (dbFetchRows("SELECT *,DATE_FORMAT(datetime, '".$config['dateformat']['mysql']['compact']."') as humandate FROM `authlog` ORDER BY `datetime` DESC LIMIT 0,250") as $entry) { foreach (dbFetchRows("SELECT *,DATE_FORMAT(datetime, '".$config['dateformat']['mysql']['compact']."') as humandate FROM `authlog` ORDER BY `datetime` DESC LIMIT 0,250") as $entry) {
if ($bg == $list_colour_a) { if ($bg == $list_colour_a) {
$bg = $list_colour_b; $bg = $list_colour_b;
@@ -12,20 +12,19 @@ if ($_SESSION['userlevel'] >= '10') {
$bg = $list_colour_a; $bg = $list_colour_a;
} }
echo "<tr style=\"background-color: $bg\"> echo "<tr>
<td class=syslog width=160> <td>
".$entry['datetime'].' ".$entry['datetime'].'
</td> </td>
<td class=list-bold width=125> <td>
'.$entry['user'].' '.$entry['user'].'
</td> </td>
<td class=syslog width=250> <td>
'.$entry['address'].' '.$entry['address'].'
</td> </td>
<td class=syslog width=150> <td>
'.$entry['result'].' '.$entry['result'].'
</td> </td>
<td></td>
'; ';
}//end foreach }//end foreach