diff --git a/html/pages/interfaces.php b/html/pages/interfaces.php index 6c607c0d50..4ad8dd4a69 100644 --- a/html/pages/interfaces.php +++ b/html/pages/interfaces.php @@ -1,6 +1,6 @@ "); @@ -14,7 +14,7 @@ while($interface = mysql_fetch_array($query)) { if(is_integer($row/2)) { $row_colour = $list_colour_a; } else { $row_colour = $list_colour_b; } $speed = humanspeed($interface['ifSpeed']); - $if_link = generateiflink($interface); + $if_link = generateiflink($interface, makeshortif($interface['ifDescr'])); $dev_link = generatedevicelink($interface); $type = humanmedia($interface['ifType']); diff --git a/includes/functions.php b/includes/functions.php index edba6fb14a..8d4e912314 100755 --- a/includes/functions.php +++ b/includes/functions.php @@ -343,6 +343,8 @@ function fixifName ($inf) { $inf = str_replace("dial", "Dial", $inf); $inf = str_replace("hp procurve switch software Loopback interface", "Loopback Interface", $inf); $inf = str_replace("control plane interface", "Control Plane", $inf); + $inf = preg_replace("", "Interface \\1", $inf); + $inf = preg_replace("/^([0-9]+)$/", "Interface \\1", $inf); return $inf; }