* Simplify by using $_REQUEST

* Hard code WAN description if it is blank
This commit is contained in:
Scott Ullrich 2008-08-28 20:19:52 +00:00
parent fa550a17b5
commit bd58d23037
2 changed files with 16 additions and 18 deletions

View File

@ -38,15 +38,10 @@
##|*MATCH=interfaces_wan.php*
##|-PRIV
unset($if);
if ($_GET['if'])
$if = $_GET['if'];
else if ($_POST['if'])
$if = $_POST['if'];
if (!$if)
$if = "wan";
if ($_REQUEST['if'])
$if = $_REQUEST['if'];
else
$if = "wan";
define("CRON_MONTHLY_PATTERN", "0 0 1 * *");
define("CRON_WEEKLY_PATTERN", "0 0 * * 0");
@ -542,6 +537,10 @@ n already exists.";
}
}
// Populate page descr if it does not exist.
if($if == "wan" && !$wancfg['descr'])
$wancfg['descr'] = "WAN";
$pgtitle = array("Interfaces", $wancfg['descr']);
$closehead = false;
include("head.inc");

View File

@ -38,15 +38,10 @@
##|*MATCH=interfaces_wan.php*
##|-PRIV
unset($if);
if ($_GET['if'])
$if = $_GET['if'];
else if ($_POST['if'])
$if = $_POST['if'];
if (!$if)
$if = "wan";
if ($_REQUEST['if'])
$if = $_REQUEST['if'];
else
$if = "wan";
define("CRON_MONTHLY_PATTERN", "0 0 1 * *");
define("CRON_WEEKLY_PATTERN", "0 0 * * 0");
@ -542,6 +537,10 @@ n already exists.";
}
}
// Populate page descr if it does not exist.
if($if == "wan" && !$wancfg['descr'])
$wancfg['descr'] = "WAN";
$pgtitle = array("Interfaces", $wancfg['descr']);
$closehead = false;
include("head.inc");