diff options
author | Ermal Luçi <eri@pfsense.org> | 2008-09-16 18:15:25 +0000 |
---|---|---|
committer | Ermal Luçi <eri@pfsense.org> | 2008-09-16 18:15:25 +0000 |
commit | 453074aa4fc90751f97b940097047bfac7a6bfef (patch) | |
tree | 92a93ba88b1b0957d46b904ccd55c9cb75b509ef /usr/local | |
parent | 99bbd213c9698e521dcce58e921ff68eb243fa19 (diff) | |
download | pfsense-453074aa4fc90751f97b940097047bfac7a6bfef.zip pfsense-453074aa4fc90751f97b940097047bfac7a6bfef.tar.gz |
* Fix 'descr'setting and displaying.
* Some white space cleanup.
Diffstat (limited to 'usr/local')
-rwxr-xr-x | usr/local/www/interfaces.php | 37 |
1 files changed, 19 insertions, 18 deletions
diff --git a/usr/local/www/interfaces.php b/usr/local/www/interfaces.php index 989ae96..f23cf30 100755 --- a/usr/local/www/interfaces.php +++ b/usr/local/www/interfaces.php @@ -150,7 +150,14 @@ $pconfig['disableftpproxy'] = isset($wancfg['disableftpproxy']); $pconfig['dhcphostname'] = $wancfg['dhcphostname']; $pconfig['alias-address'] = $wancfg['alias-address']; $pconfig['alias-subnet'] = $wancfg['alias-subnet']; + +// Populate page descr if it does not exist. +if($if == "wan" && !$wancfg['descr']) + $wancfg['descr'] = "WAN"; +else if ($if == "lan" && !$wancfg['descr']) + $wancfg['descr'] = "LAN"; $pconfig['descr'] = remove_bad_chars($wancfg['descr']); + if ($if == "wan" || $if == "lan") $pconfig['enable'] = true; else @@ -711,20 +718,20 @@ n already exists."; /* finally install the pppoerestart file */ if (isset($_POST['pppoe_preset'])) { - config_lock(); - conf_mount_rw(); + config_lock(); + conf_mount_rw(); - if (! file_exists(CRON_PPPOE_CMD_FILE)) { - file_put_contents(CRON_PPPOE_CMD_FILE, CRON_PPPOE_CMD); - chmod(CRON_PPPOE_CMD_FILE, 0700); - } + if (! file_exists(CRON_PPPOE_CMD_FILE)) { + file_put_contents(CRON_PPPOE_CMD_FILE, CRON_PPPOE_CMD); + chmod(CRON_PPPOE_CMD_FILE, 0700); + } - /* regenerate cron settings/crontab file */ - configure_cron(); - sigkillbypid("{$g['varrun_path']}/cron.pid", "HUP"); + /* regenerate cron settings/crontab file */ + configure_cron(); + sigkillbypid("{$g['varrun_path']}/cron.pid", "HUP"); - conf_mount_ro(); - config_unlock(); + conf_mount_ro(); + config_unlock(); } $retval = 0; @@ -736,13 +743,7 @@ n already exists."; } } -// Populate page descr if it does not exist. -if($if == "wan" && !$wancfg['descr']) - $wancfg['descr'] = "WAN"; -else if ($if == "lan" && !$wancfg['descr']) - $wancfg['descr'] = "LAN"; - -$pgtitle = array("Interfaces", $wancfg['descr']); +$pgtitle = array("Interfaces", $pconfig['descr']); $closehead = false; include("head.inc"); |