} echo ")</td>"; } echo "</tr>"; //DOWNLOAD_CYCLE_LATENCY optperso("DOWNLOAD_CYCLE_LATENCY", $l->g(720) . " <font color=green size=1><i>DOWNLOAD_CYCLE_LATENCY</i></font>", $optPerso, 0, $optdefault['ivalue']["DOWNLOAD_CYCLE_LATENCY"], $l->g(511)); //DOWNLOAD_FRAG_LATENCY optperso("DOWNLOAD_FRAG_LATENCY", $l->g(721) . " <font color=green size=1><i>DOWNLOAD_FRAG_LATENCY</i></font>", $optPerso, 0, $optdefault['ivalue']["DOWNLOAD_FRAG_LATENCY"], $l->g(511)); //DOWNLOAD_PERIOD_LATENCY optperso("DOWNLOAD_PERIOD_LATENCY", $l->g(722) . " <font color=green size=1><i>DOWNLOAD_PERIOD_LATENCY</i></font>", $optPerso, 0, $optdefault['ivalue']["DOWNLOAD_PERIOD_LATENCY"], $l->g(511)); //DOWNLOAD_PERIOD_LENGTH optperso("DOWNLOAD_PERIOD_LENGTH", $l->g(723) . " <font color=green size=1><i>DOWNLOAD_PERIOD_LENGTH</i></font>", $optPerso, 0, $optdefault['ivalue']["DOWNLOAD_PERIOD_LENGTH"]); //PROLOG_FREQ optperso("PROLOG_FREQ", $l->g(724) . " <font color=green size=1><i>PROLOG_FREQ</i></font>", $optPerso, 0, $optdefault['ivalue']["PROLOG_FREQ"], $l->g(730)); //PROLOG_FREQ optperso("DOWNLOAD_TIMEOUT", $l->g(424) . " <font color=green size=1><i>DOWNLOAD_TIMEOUT</i></font>", $optPerso, 0, $optdefault['ivalue']["DOWNLOAD_TIMEOUT"], $l->g(496)); //PROLOG_FREQ //optperso("SNMP_SWITCH",$l->g(1197)." <font color=green size=1><i>SNMP_SWITCH</i></font>",$optPerso,0,$optdefault["SNMP_SWITCH"],$l->g(496)); //DOWNLOAD_SWITCH echo "<tr><td bgcolor='white' align='center' valign='center'>" . (isset($optPerso["SNMP_SWITCH"]) ? "<img width='15px' src='image/red.png'>" : " ") . "</td>"; echo $td3 . $l->g(1197) . " <font color=green size=1><i>SNMP_SWITCH</i></font></td>"; if (isset($optPerso["SNMP_SWITCH"])) { if ($optPerso["SNMP_SWITCH"]["IVALUE"] == 0) { echo $td3 . $l->g(733) . "</td>"; } else { if ($optPerso["SNMP_SWITCH"]["IVALUE"] == 1) { echo $td3 . $l->g(205) . "</td>"; } else { echo $td3 . "</td>"; } }
function print_perso($systemid) { global $l, $td1, $td2, $td3, $td4, $pages_refs, $protectedGet; $i = 0; $queryDetails = "SELECT * FROM devices WHERE hardware_id={$systemid}"; $resultDetails = mysql_query($queryDetails, $_SESSION['OCS']["readServer"]) or die(mysql_error($_SESSION['OCS']["readServer"])); $form_name = 'config_group'; echo open_form($form_name); echo "<table BORDER='0' WIDTH = '95%' ALIGN = 'Center' CELLPADDING='0' BGCOLOR='#C7D9F5' BORDERCOLOR='#9894B5'>"; //echo "<tr><td> </td> $td1 "."Libell�"." </td> $td1 "."Valeur"." </td><td> </td></tr>"; while ($item = mysql_fetch_array($resultDetails, MYSQL_ASSOC)) { $optPerso[$item["NAME"]]["IVALUE"] = $item["IVALUE"]; $optPerso[$item["NAME"]]["TVALUE"] = $item["TVALUE"]; } $ii++; $td3 = $ii % 2 == 0 ? $td2 : $td4; //IPDISCOVER echo "<tr><td bgcolor='white' align='center' valign='center'>" . (isset($optPerso["IPDISCOVER"]) && $optPerso["IPDISCOVER"]["IVALUE"] != 1 ? "<img width='15px' src='image/red.png'>" : " ") . "</td> </td>"; echo $td3 . $l->g(489) . "</td>"; if (isset($optPerso["IPDISCOVER"])) { if ($optPerso["IPDISCOVER"]["IVALUE"] == 0) { echo $td3 . $l->g(490) . "</td>"; } else { if ($optPerso["IPDISCOVER"]["IVALUE"] == 2) { echo $td3 . $l->g(491) . " " . $optPerso["IPDISCOVER"]["TVALUE"] . "</td>"; } else { if ($optPerso["IPDISCOVER"]["IVALUE"] == 1) { echo $td3 . $l->g(492) . " " . $optPerso["IPDISCOVER"]["TVALUE"] . "</td>"; } } } } else { echo $td3 . $l->g(493) . "</td>"; } if ($_SESSION['OCS']['CONFIGURATION']['CONFIG'] == "YES") { echo "<td align=center rowspan=8><a href=# Onclick=window.open(\"index.php?" . PAG_INDEX . "=" . $pages_refs['ms_custom_param'] . "&head=1&idchecked=" . $systemid . "&origine=group\",\"rollo\",\"location=0,status=0,scrollbars=1,menubar=0,resizable=0,width=800,height=500\");>\n\t\t<img src='image/modif_a.png' title='" . $l->g(285) . "'></a></td></tr>"; } $ii++; $td3 = $ii % 2 == 0 ? $td2 : $td4; $field_name = array('DOWNLOAD', 'DOWNLOAD_CYCLE_LATENCY', 'DOWNLOAD_PERIOD_LENGTH', 'DOWNLOAD_FRAG_LATENCY', 'DOWNLOAD_PERIOD_LATENCY', 'DOWNLOAD_TIMEOUT', 'PROLOG_FREQ', 'SNMP'); $optdefault = look_config_default_values($field_name); //FREQUENCY echo "<tr><td bgcolor='white' align='center' valign='center'>" . (isset($optPerso["FREQUENCY"]) ? "<img width='15px' src='image/red.png'>" : " ") . "</td>"; echo $td3 . $l->g(494) . "</td>"; if (isset($optPerso["FREQUENCY"])) { if ($optPerso["FREQUENCY"]["IVALUE"] == 0) { echo $td3 . $l->g(485) . "</td>"; } else { if ($optPerso["FREQUENCY"]["IVALUE"] == -1) { echo $td3 . $l->g(486) . "</td>"; } else { echo $td3 . $l->g(495) . " " . $optPerso["FREQUENCY"]["IVALUE"] . " " . $l->g(496) . "</td>"; } } } else { echo $td3 . $l->g(497) . "</td>"; } echo "</tr>"; //DOWNLOAD_SWITCH echo "<tr><td bgcolor='white' align='center' valign='center'>" . (isset($optPerso["DOWNLOAD_SWITCH"]) ? "<img width='15px' src='image/red.png'>" : " ") . "</td>"; echo $td3 . $l->g(417) . " <font color=green size=1><i>DOWNLOAD</i></font> </td>"; if (isset($optPerso["DOWNLOAD_SWITCH"])) { if ($optPerso["DOWNLOAD_SWITCH"]["IVALUE"] == 0) { echo $td3 . $l->g(733) . "</td>"; } else { if ($optPerso["DOWNLOAD_SWITCH"]["IVALUE"] == 1) { echo $td3 . $l->g(205) . "</td>"; } else { echo $td3 . "</td>"; } } } else { echo $td3 . $l->g(488) . "("; if ($optdefault['ivalue']["DOWNLOAD"] == 1) { echo $l->g(205); } else { echo $l->g(733); } echo ")</td>"; } echo "</tr>"; //DOWNLOAD_CYCLE_LATENCY optperso("DOWNLOAD_CYCLE_LATENCY", $l->g(720) . " <font color=green size=1><i>DOWNLOAD_CYCLE_LATENCY</i></font>", $optPerso, 1, $optdefault['ivalue']["DOWNLOAD_CYCLE_LATENCY"], $l->g(511)); //DOWNLOAD_FRAG_LATENCY optperso("DOWNLOAD_FRAG_LATENCY", $l->g(721) . " <font color=green size=1><i>DOWNLOAD_FRAG_LATENCY</i></font>", $optPerso, 1, $optdefault['ivalue']["DOWNLOAD_FRAG_LATENCY"], $l->g(511)); //DOWNLOAD_PERIOD_LATENCY optperso("DOWNLOAD_PERIOD_LATENCY", $l->g(722) . " <font color=green size=1><i>DOWNLOAD_PERIOD_LATENCY</i></font>", $optPerso, 1, $optdefault['ivalue']["DOWNLOAD_PERIOD_LATENCY"], $l->g(511)); //DOWNLOAD_PERIOD_LENGTH optperso("DOWNLOAD_PERIOD_LENGTH", $l->g(723) . " <font color=green size=1><i>DOWNLOAD_PERIOD_LENGTH</i></font>", $optPerso, 1, $optdefault['ivalue']["DOWNLOAD_PERIOD_LENGTH"]); //PROLOG_FREQ optperso("PROLOG_FREQ", $l->g(724) . " <font color=green size=1><i>PROLOG_FREQ</i></font>", $optPerso, 1, $optdefault['ivalue']["PROLOG_FREQ"], $l->g(730)); //SNMP_SWITCH echo "<tr><td bgcolor='white' align='center' valign='center'>" . (isset($optPerso["SNMP_SWITCH"]) ? "<img width='15px' src='image/red.png'>" : " ") . "</td>"; echo $td3 . $l->g(1197) . " <font color=green size=1><i>SNMP_SWITCH</i></font></td>"; if (isset($optPerso["SNMP_SWITCH"])) { if ($optPerso["SNMP_SWITCH"]["IVALUE"] == 0) { echo $td3 . $l->g(733) . "</td>"; } else { if ($optPerso["SNMP_SWITCH"]["IVALUE"] == 1) { echo $td3 . $l->g(205) . "</td>"; } else { echo $td3 . "</td>"; } } } else { echo $td3 . $l->g(488) . "("; if ($optdefault['ivalue']["SNMP"] == 1) { echo $l->g(205); } else { echo $l->g(733); } echo ")</td>"; } echo "</tr>"; //TELEDEPLOY require_once 'require/function_machine.php'; show_packages($systemid, "ms_group_show"); if ($_SESSION['OCS']['CONFIGURATION']['TELEDIFF'] == "YES") { echo "<tr>\n\t\t<td colspan='10' align='right'>\n\t\t<a href=# Onclick=window.open(\"index.php?" . PAG_INDEX . "=" . $pages_refs['ms_custom_pack'] . "&head=1&idchecked=" . $systemid . "&origine=group\",\"rollo\",\"location=0,status=0,scrollbars=1,menubar=0,resizable=0,width=800,height=500\");>" . $l->g(501) . "\n\t\t</a>\n\t\t</td></tr>"; } echo "</table><br>"; echo close_form(); }