summaryrefslogtreecommitdiffstats
path: root/usr/local/www/diag_arp.php
diff options
context:
space:
mode:
authorRenato Botelho <renato.botelho@bluepex.com>2010-06-30 09:30:01 -0300
committerRenato Botelho <renato.botelho@bluepex.com>2010-06-30 09:30:01 -0300
commit0b3abd3b5639676b27a78e651c6753c38e6c8bbe (patch)
treee727ffd9d36f8d868a5d080213fddcf79ef7f5b6 /usr/local/www/diag_arp.php
parenta5e9c28444e3dc6a3c1668719786c3a389ba652e (diff)
downloadpfsense-0b3abd3b5639676b27a78e651c6753c38e6c8bbe.zip
pfsense-0b3abd3b5639676b27a78e651c6753c38e6c8bbe.tar.gz
Reset diag_ files
Diffstat (limited to 'usr/local/www/diag_arp.php')
-rwxr-xr-xusr/local/www/diag_arp.php32
1 files changed, 16 insertions, 16 deletions
diff --git a/usr/local/www/diag_arp.php b/usr/local/www/diag_arp.php
index 3aff783..4a6e92c 100755
--- a/usr/local/www/diag_arp.php
+++ b/usr/local/www/diag_arp.php
@@ -205,15 +205,15 @@ if(count($pools) > 0) {
// Put this in an easy to use form
$dhcpmac = array();
$dhcpip = array();
-
+
foreach ($leases as $value) {
- $dhcpmac[$value['mac']] = $value['hostname'];
- $dhcpip[$value['ip']] = $value['hostname'];
+ $dhcpmac[$value['mac']] = $value['hostname'];
+ $dhcpip[$value['ip']] = $value['hostname'];
}
exec("/usr/sbin/arp -an",$rawdata);
-$i = 0;
+$i = 0;
/* if list */
$ifdescrs = get_configured_interface_with_descr();
@@ -225,7 +225,7 @@ foreach ($ifdescrs as $key =>$interface) {
$data = array();
foreach ($rawdata as $line) {
$elements = explode(' ',$line);
-
+
if ($elements[3] != "(incomplete)") {
$arpent = array();
$arpent['ip'] = trim(str_replace(array('(',')'),'',$elements[1]));
@@ -238,28 +238,28 @@ foreach ($rawdata as $line) {
function getHostName($mac,$ip)
{
global $dhcpmac, $dhcpip;
-
+
if ($dhcpmac[$mac])
return $dhcpmac[$mac];
else if ($dhcpip[$ip])
return $dhcpip[$ip];
else if(gethostbyaddr($ip) <> "" and gethostbyaddr($ip) <> $ip)
return gethostbyaddr($ip);
- else
- return "";
+ else
+ return "";
}
-$pgtitle = array(gettext("Diagnostics"),gettext("ARP Table"));
+$pgtitle = array("Diagnostics","ARP Table");
include("head.inc");
?>
<body link="#000000" vlink="#000000" alink="#000000">
-
+
<?php include("fbegin.inc"); ?>
<div id="loading">
- <img src="/themes/{$g['theme']}/images/misc/loader.gif"><?= gettext("Loading, please wait..."); ?>
+ <img src="/themes/{$g['theme']}/images/misc/loader.gif"> Loading, please wait...
<p/>&nbsp;
</div>
@@ -276,7 +276,7 @@ foreach ($data as &$entry) {
$dns = trim(getHostName($entry['mac'], $entry['ip']));
if(trim($dns))
$entry['dnsresolve'] = "$dns";
- else
+ else
$entry['dnsresolve'] = "Z_ ";
}
@@ -289,10 +289,10 @@ $data = msort($data, "dnsresolve");
<td>
<table class="tabcont sortable" width="100%" border="0" cellpadding="0" cellspacing="0">
<tr>
- <td class="listhdrr"><?= gettext("IP address"); ?></td>
- <td class="listhdrr"><?= gettext("MAC address"); ?></td>
- <td class="listhdrr"><?= gettext("Hostname"); ?></td>
- <td class="listhdr"><?= gettext("Interface"); ?></td>
+ <td class="listhdrr">IP address</td>
+ <td class="listhdrr">MAC address</td>
+ <td class="listhdrr">Hostname</td>
+ <td class="listhdr">Interface</td>
<td class="list"></td>
</tr>
<?php foreach ($data as $entry): ?>
OpenPOWER on IntegriCloud