summaryrefslogtreecommitdiffstats
path: root/usr
diff options
context:
space:
mode:
authorErmal Luçi <eri@pfsense.org>2009-10-05 18:48:32 +0000
committerErmal Luçi <eri@pfsense.org>2009-10-05 18:49:42 +0000
commit203de6bf85842920513168600e4f397a41c13b7b (patch)
treeb661f0cc8b139b1048d4413892e4e699100ce9ca /usr
parent8586a962022b11a791baa0e9184f49c5156850f1 (diff)
downloadpfsense-203de6bf85842920513168600e4f397a41c13b7b.zip
pfsense-203de6bf85842920513168600e4f397a41c13b7b.tar.gz
Remove support for all_interfaces from wizard.php it is not used anywhere. Convert the interfaces_selection to use the interface API.
Diffstat (limited to 'usr')
-rwxr-xr-xusr/local/www/pkg_edit.php2
-rwxr-xr-xusr/local/www/wizard.php23
2 files changed, 4 insertions, 21 deletions
diff --git a/usr/local/www/pkg_edit.php b/usr/local/www/pkg_edit.php
index 675899a..841eedb 100755
--- a/usr/local/www/pkg_edit.php
+++ b/usr/local/www/pkg_edit.php
@@ -465,7 +465,7 @@ if ($pkg['tabs'] <> "") {
if (isset($pkga['all_interfaces']))
$ifaces = explode(' ', trim(shell_exec('ifconfig -l')));
else
- $ifaces = $config['interfaces'];
+ $ifaces = get_configured_interface_with_descr();
$additional_ifaces = $pkga['add_to_interfaces_selection'];
if (!empty($additional_ifaces))
$ifaces = array_merge($ifaces, explode(',', $additional_ifaces));
diff --git a/usr/local/www/wizard.php b/usr/local/www/wizard.php
index b1d32f5..d7113bb 100755
--- a/usr/local/www/wizard.php
+++ b/usr/local/www/wizard.php
@@ -343,32 +343,15 @@ function enablechange() {
if($field['add_to_interfaces_selection'] == $value) $SELECTED = " SELECTED";
echo "<option value='" . $field['add_to_interfaces_selection'] . "'" . $SELECTED . ">" . $field['add_to_interfaces_selection'] . "</option>\n";
}
- $interfaces = $config['interfaces'];
- if($field['all_interfaces'] <> "") {
- $ints = split(" ", `/sbin/ifconfig -l`);
- $interfaces = array();
- foreach ($ints as $int) {
- $interfaces[]['descr'] = $int;
- $interfaces[] = $int;
- }
- }
+ $interfaces = get_configured_interface_with_descr();
foreach ($interfaces as $ifname => $iface) {
- if ($iface['descr'])
- $ifdescr = $iface['descr'];
- else
- $ifdescr = strtoupper($ifname);
- $ip = "";
- if($field['all_interfaces'] <> "") {
- $ifdescr = $iface;
- $ip = " " . find_interface_ip($iface);
- }
$SELECTED = "";
if ($value == $ifname) $SELECTED = " SELECTED";
- $to_echo = "<option value='" . $ifname . "'" . $SELECTED . ">" . $ifdescr . $ip . "</option>\n";
+ $to_echo = "<option value='" . $ifname . "'" . $SELECTED . ">" . $iface . "</option>\n";
$to_echo .= "<!-- {$value} -->";
$canecho = 0;
if($field['interface_filter'] <> "") {
- if(stristr($iface, $field['interface_filter']) == true)
+ if(stristr($ifname, $field['interface_filter']) == true)
$canecho = 1;
} else {
$canecho = 1;
OpenPOWER on IntegriCloud