function dhcp_computers_scripts() { $dhc = new dhcpd(); $array = $dhc->LoadfixedAddresses(); if (!is_array($array)) { return null; } $html = "\n\t<table style='width:100%'>\n\t"; $html = "\n<table cellspacing='0' cellpadding='0' border='0' class='tableView' style='width:99.5%'>\n<thead class='thead'>\n\t<tr>\n\t<th colspan=4> {fixedHosts}</th>\n\t</tr>\n</thead>\n<tbody class='tbody'>"; while (list($num, $ligne) = each($array)) { if (preg_match("#^[0-9]+\\.[0-9]+\\.[0-9]+\\.[0-9]+\$#", trim($num))) { continue; } if ($classtr == "oddRow") { $classtr = null; } else { $classtr = "oddRow"; } $ligne["MAC"] = str_replace("hardware ethernet", "", $ligne["MAC"]); $js = MEMBER_JS("{$num}\$", 1, 1); $html = $html . "\n\t\t<tr class={$classtr}>\n\t\t\t<td valign='top'><img src='img/computer-32.png'></td>\n\t\t\t<td><strong><a href=\"javascript:blur();\" OnClick=\"javascript:{$js}\" style='font-size:14px'>{$num}</a></td>\n\t\t\t<td><strong><a href=\"javascript:blur();\" OnClick=\"javascript:{$js}\" style='font-size:14px'>{$ligne["MAC"]}</a></td>\n\t\t\t<td><strong><a href=\"javascript:blur();\" OnClick=\"javascript:{$js}\" style='font-size:14px'>{$ligne["IP"]}</a></td>\n\t\t</tr>\n\t\t\t\n\t\t"; } $html = $html . "</tbody></table>"; $tpl = new templates(); return RoundedLightWhite($tpl->_ENGINE_parse_body($html)); }
function dhcp_computers_scripts() { $dhc = new dhcpd(); $array = $dhc->LoadfixedAddresses(); if (!is_array($array)) { return null; } $html = "<H3 style='color:#005447'>{fixedHosts}</H3>\n\t<table style='width:100%'>\n\t"; while (list($num, $ligne) = each($array)) { $ligne["MAC"] = str_replace("hardware ethernet", "", $ligne["MAC"]); $js = MEMBER_JS("{$num}\$", 1); $html = $html . "\n\t\t<tr " . CellRollOver($js) . ">\n\t\t\t<td valign='top'><img src='img/base.gif'></td>\n\t\t\t<td><strong>{$num}</td>\n\t\t\t<td><strong>{$ligne["MAC"]}</td>\n\t\t\t<td><strong>{$ligne["IP"]}</td>\n\t\t</tr>\n\t\t\t\n\t\t"; } $html = $html . "</table>"; $tpl = new templates(); return RoundedLightWhite($tpl->_ENGINE_parse_body($html)); }