summaryrefslogtreecommitdiffstats
path: root/src/usr/local/www/firewall_nat_1to1.php
diff options
context:
space:
mode:
authorPhil Davis <phil.davis@inf.org>2015-12-14 23:18:15 +0545
committerPhil Davis <phil.davis@inf.org>2015-12-14 23:18:15 +0545
commit67c2baf157c50ae1b545f36bcf6afee6cdf6f67c (patch)
treec429615f87c26b3da9c58c7149d827a893461dbe /src/usr/local/www/firewall_nat_1to1.php
parent935b578b7606b8af6866c3c01e9e7b7f9c58a0d9 (diff)
downloadpfsense-67c2baf157c50ae1b545f36bcf6afee6cdf6f67c.zip
pfsense-67c2baf157c50ae1b545f36bcf6afee6cdf6f67c.tar.gz
Coe style firewall *
Diffstat (limited to 'src/usr/local/www/firewall_nat_1to1.php')
-rw-r--r--src/usr/local/www/firewall_nat_1to1.php14
1 files changed, 9 insertions, 5 deletions
diff --git a/src/usr/local/www/firewall_nat_1to1.php b/src/usr/local/www/firewall_nat_1to1.php
index a2213b8..0995cb8 100644
--- a/src/usr/local/www/firewall_nat_1to1.php
+++ b/src/usr/local/www/firewall_nat_1to1.php
@@ -78,18 +78,20 @@ if (!is_array($config['nat']['onetoone'])) {
$a_1to1 = &$config['nat']['onetoone'];
/* update rule order, POST[rule] is an array of ordered IDs */
-if($_POST['order-store']) {
+if ($_POST['order-store']) {
if (is_array($_POST['rule']) && !empty($_POST['rule'])) {
$a_1to1_new = array();
// if a rule is not in POST[rule], it has been deleted by the user
- foreach ($_POST['rule'] as $id)
+ foreach ($_POST['rule'] as $id) {
$a_1to1_new[] = $a_1to1[$id];
+ }
$a_1to1 = $a_1to1_new;
- if (write_config())
+ if (write_config()) {
mark_subsystem_dirty('natconf');
+ }
header("Location: firewall_nat_1to1.php");
exit;
@@ -156,12 +158,14 @@ if (isset($_POST['del_x'])) {
$pgtitle = array(gettext("Firewall"), gettext("NAT"), gettext("1:1"));
include("head.inc");
-if ($savemsg)
+if ($savemsg) {
print_info_box($savemsg, 'success');
+}
-if (is_subsystem_dirty('natconf'))
+if (is_subsystem_dirty('natconf')) {
print_info_box_np(gettext('The NAT configuration has been changed.') . '<br />' .
gettext('You must apply the changes in order for them to take effect.') . '<br />');
+}
$tab_array = array();
$tab_array[] = array(gettext("Port Forward"), false, "firewall_nat.php");
OpenPOWER on IntegriCloud