diff options
Diffstat (limited to 'ldap-site-mngmt/webinterface/computers/ip_rechner.php')
| -rw-r--r-- | ldap-site-mngmt/webinterface/computers/ip_rechner.php | 11 |
1 files changed, 9 insertions, 2 deletions
diff --git a/ldap-site-mngmt/webinterface/computers/ip_rechner.php b/ldap-site-mngmt/webinterface/computers/ip_rechner.php index 5870f503..fcc04883 100644 --- a/ldap-site-mngmt/webinterface/computers/ip_rechner.php +++ b/ldap-site-mngmt/webinterface/computers/ip_rechner.php @@ -9,7 +9,7 @@ include('computers_header.inc.php'); ############################################################################# -$mnr = 2; +$mnr = 1; $sbmnr = -1; $mcnr = -1; @@ -19,6 +19,9 @@ createComputersMenu($rollen, $mnr, $auDN, $sbmnr, $mcnr); ############################################################################# +$sort = "hostname"; +$sort = $_GET['sort']; + $template->assign(array("IP" => "", "OLDIP" => "", "DHCPCONT" => "", @@ -26,9 +29,13 @@ $template->assign(array("IP" => "", "HOSTNAME" => "Noch keine Rechner angelegt", "HOSTDN" => "")); -$host_array = get_hosts($auDN,array("dn","hostname","ipaddress","dhcphlpcont","dhcpoptfixed-address")); +$host_array = get_hosts($auDN,array("dn","hostname","ipaddress","dhcphlpcont","dhcpoptfixed-address"),$sort); # print_r ($host_array); +if ($sort == "ipaddress"){ + $host_array = array_natsort($host_array, "ipaddress", "ipaddress"); +} + $template->define_dynamic("Hosts", "Webseite"); foreach ($host_array as $host){ |
