Exemple #1
0
<th><?php 
echo _("Last Connect");
?>
</th>
<th><?php 
echo _("Sensor");
?>
</th>
<th></th>
<?php 
$sids = "";
if ($sensors != "") {
    $sensor_list = explode(",", $sensors);
    $sids = Wireless::get_sids($conn, $sensor_list);
}
$aps = Wireless::get_aps($conn, $ssid, $sids);
$i = 0;
foreach ($aps as $data) {
    $color = $i++ % 2 == 0 ? "bgcolor='#f2f2f2'" : "";
    echo "<tr {$color}>\n\t<td>" . $data['mac'] . "</td>\n\t<td style='padding:0px 10px 0px 10px;text-align:left'>" . $data['vendor'] . "</td>\n\t<td>" . $data['clients'] . "</td>\n\t<td>" . $data['freq'] . "</td>\n\t<td>" . $data['channel'] . "</td>\n\t<td>" . $data['type'] . "</td>\n\t<td>" . $data['first'] . "</td>\n\t<td>" . $data['last'] . "</td>\n\t<td>-</td>\n\t<td width='20'>\n\t\t<a href='ap_edit.php?ssid=" . urlencode(base64_encode($ssid)) . "&mac=" . urlencode($data['mac']) . "'><img src='../repository/images/edit.gif' border=0></a>\n\t</td>\n\t</tr>";
    $details = Wireless::get_ap_data($ossim, $data['mac']);
    if ($details['notes'] != "") {
        echo "<tr {$color}><td colspan=10 style='text-align:left;padding:0px 10px 10px 0px'><img src='../pixmaps/theme/arrow-315-small.png' border=0 align=absmiddle><b>Notes:</b> " . utf8_encode(nl2br($details['notes'])) . "</td></tr>";
    }
}
?>
</table><br>
</body>
</html>
<?php 
$db->close($conn);