$pagetitle="HOSTS DATENBANK E136"; $pageheadline="List of Hosts E136"; include "../netheader.phtml"; include "../netfuncs.php"; mysql_connect("localhost","wwwpublic",""); mysql_select_db("net"); if ($sort==1): $o = "hostdb.ip"; endif; if ($sort==2): $o = "hostdb.hostname"; endif; if ($sort==3): $o = "patchverbindung.switch,patchverbindung.port"; endif; if ($sort==4): $o = "patchverbindung.room,patchverbindung.dose"; endif; if (strlen($hostname)): /* $hostname = msql_regcase($hostname); */ $rule = "where hostdb.hostname like '%$hostname%'"; endif; if (strlen($ip)): $rule = addAnd($rule, "hostdb.ip like '%$ip%'"); endif; if (strlen($switch)): $rule = addAnd($rule, "patchverbindung.switch like '%$switch'"); endif; if (strlen($user)): $rule = addAnd($rule, "hostdb.user like '%$user%'"); endif; if (strlen($room)): $rule = addAnd($rule, "patchverbindung.room like '%$room%'"); endif; $rule = addAnd($rule, "hostdb.id=patchverbindung.id"); $select = "hostdb.id,hostdb.ip,hostdb.hostname,patchverbindung.room,patchverbindung.dose,patchverbindung.switch,patchverbindung.port,hostdb.user,hostdb.type"; $from = "hostdb,patchverbindung"; $result = mysql_query("SELECT $select FROM $from $rule ORDER BY $o"); $nhit = mysql_num_rows($result); $i=0; ?>
| Switch/Hub | Port | Zimmer-Dose | HOSTNAME | IP Adresse if ($f=="l"): ?> | Comment | User | Last Changed endif; ?> | |
| "> echo $i+1;?> | echo mysql_result($result,$i,"patchverbindung.switch");?> | echo mysql_result($result,$i,"patchverbindung.port");?> | %27"> echo mysql_result($result,$i,"patchverbindung.room");?> if (mysql_result($result,$i,"patchverbindung.dose")!=""):?> - echo mysql_result($result,$i,"patchverbindung.dose");?> endif;?> | %27"> echo mysql_result($result,$i,"hostdb.hostname");?> | echo mysql_result($result,$i,"hostdb.ip");?> if ($f=="l"):?> | echo mysql_result($result,$i,"hostdb.type");?> | echo mysql_result($result,$i,"hostdb.user");?> endif;?> |