summaryrefslogtreecommitdiffstats
path: root/usr
diff options
context:
space:
mode:
authorScott Ullrich <sullrich@pfsense.org>2010-11-06 14:00:11 -0400
committerScott Ullrich <sullrich@pfsense.org>2010-11-06 14:00:11 -0400
commitd815d5faecddfdf1d7064b0143df9fbe017af5d5 (patch)
treef9baabf6a709dfed7d760b1ea7bacabdb5953657 /usr
parent98bcf1f8b57478833f65e3309d0cc98ba4933c0a (diff)
downloadpfsense-d815d5faecddfdf1d7064b0143df9fbe017af5d5.zip
pfsense-d815d5faecddfdf1d7064b0143df9fbe017af5d5.tar.gz
Use get_configured_interface_list() so Ermal does not yell at me :)
Diffstat (limited to 'usr')
-rwxr-xr-xusr/local/www/interfaces.php7
-rwxr-xr-xusr/local/www/status_graph.php8
2 files changed, 2 insertions, 13 deletions
diff --git a/usr/local/www/interfaces.php b/usr/local/www/interfaces.php
index 218e6bf..cd9efd3 100755
--- a/usr/local/www/interfaces.php
+++ b/usr/local/www/interfaces.php
@@ -54,15 +54,10 @@ require_once("rrd.inc");
require_once("vpn.inc");
require_once("xmlparse_attr.inc");
-$ifdescrs = array('wan' => gettext('WAN'), 'lan' => gettext('LAN'));
-for($j = 1; isset($config['interfaces']['opt' . $j]); $j++) {
- if(isset($config['interfaces']['opt' . $j]['enable']))
- $ifdescrs['opt' . $j] = $config['interfaces']['opt' . $j]['descr'];
-}
-
if ($_REQUEST['if']) {
$if = $_REQUEST['if'];
$found = false;
+ $ifdescrs = get_configured_interface_list();
foreach($ifdescrs as $descr => $ifdescr)
if($descr == $if)
$found = true;
diff --git a/usr/local/www/status_graph.php b/usr/local/www/status_graph.php
index 6397d75..21c7fba 100755
--- a/usr/local/www/status_graph.php
+++ b/usr/local/www/status_graph.php
@@ -54,16 +54,10 @@ if ($_POST['height'])
else
$height = "200";
-$ifdescrs = array('wan' => gettext('WAN'), 'lan' => gettext('LAN'));
-
-for($j = 1; isset($config['interfaces']['opt' . $j]); $j++) {
- if(isset($config['interfaces']['opt' . $j]['enable']))
- $ifdescrs['opt' . $j] = $config['interfaces']['opt' . $j]['descr'];
-}
-
if ($_GET['if']) {
$curif = $_GET['if'];
$found = false;
+ $ifdescrs = get_configured_interface_list();
foreach($ifdescrs as $descr => $ifdescr)
if($descr == $curif) $found = true;
if(!$found) {
OpenPOWER on IntegriCloud