function printRoutersTD($rlist, $as_cell = 'yes') { $rtrclass = 'tdleft'; foreach ($rlist as $rtr) { $tmp = getIPAddress($rtr['ip_bin']); if ($tmp['class'] == 'trerror') { $rtrclass = 'tdleft trerror'; break; } } echo "<td class='{$rtrclass}'>"; $pfx = ''; foreach ($rlist as $rtr) { $rinfo = spotEntity('object', $rtr['id']); if ($as_cell == 'yes') { renderRouterCell($rtr['ip_bin'], $rtr['iface'], $rinfo); } else { echo $pfx . '<a href="' . makeHref(array('page' => 'object', 'object_id' => $rtr['id'], 'tab' => 'default', 'hl_ip' => ip_format($rtr['ip_bin']))) . '">' . $rinfo['dname'] . '</a>'; } $pfx = "<br>\n"; } echo '</td>'; }
function printRoutersTD($rlist, $as_cell = 'yes') { $rtrclass = 'tdleft'; foreach ($rlist as $rtr) { $tmp = getIPAddress($rtr['ip_bin']); if ($tmp['class'] == 'trerror') { $rtrclass = 'tdleft trerror'; break; } } echo "<td class='{$rtrclass}'>"; $pfx = ''; foreach ($rlist as $rtr) { $rinfo = spotEntity('object', $rtr['id']); if ($as_cell == 'yes') { renderRouterCell($rtr['ip_bin'], $rtr['iface'], $rinfo); } else { echo $pfx . mkA($rinfo['dname'], 'object', $rinfo['id']); } $pfx = "<br>\n"; } echo '</td>'; }