From 299144a0bea38c2844026095c9bb4c831b4e16b2 Mon Sep 17 00:00:00 2001 From: Franco Fichtner Date: Sat, 23 Jun 2018 12:54:22 +0200 Subject: [PATCH] unbound: style in ACL page --- src/www/services_unbound_acls.php | 60 +++++++++++++++---------------- 1 file changed, 30 insertions(+), 30 deletions(-) diff --git a/src/www/services_unbound_acls.php b/src/www/services_unbound_acls.php index 919fa1b52..c43552001 100644 --- a/src/www/services_unbound_acls.php +++ b/src/www/services_unbound_acls.php @@ -1,31 +1,31 @@ - All rights reserved. - - Redistribution and use in source and binary forms, with or without - modification, are permitted provided that the following conditions are met: - - 1. Redistributions of source code must retain the above copyright notice, - this list of conditions and the following disclaimer. - - 2. Redistributions in binary form must reproduce the above copyright - notice, this list of conditions and the following disclaimer in the - documentation and/or other materials provided with the distribution. - - THIS SOFTWARE IS PROVIDED ``AS IS'' AND ANY EXPRESS OR IMPLIED WARRANTIES, - INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY - AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE - AUTHOR BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, - OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF - SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS - INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN - CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) - ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE - POSSIBILITY OF SUCH DAMAGE. -*/ + * Copyright (C) 2014-2016 Deciso B.V. + * Copyright (C) 2011 Warren Baker + * All rights reserved. + * + * Redistribution and use in source and binary forms, with or without + * modification, are permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, + * this list of conditions and the following disclaimer. + * + * 2. Redistributions in binary form must reproduce the above copyright + * notice, this list of conditions and the following disclaimer in the + * documentation and/or other materials provided with the distribution. + * + * THIS SOFTWARE IS PROVIDED ``AS IS'' AND ANY EXPRESS OR IMPLIED WARRANTIES, + * INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY + * AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE + * AUTHOR BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, + * OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF + * SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS + * INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN + * CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) + * ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE + * POSSIBILITY OF SUCH DAMAGE. + */ require_once("guiconfig.inc"); require_once("system.inc"); @@ -34,7 +34,6 @@ require_once("interfaces.inc"); $a_acls = &config_read_array('unbound', 'acls'); - if ($_SERVER['REQUEST_METHOD'] === 'GET') { if (isset($_GET['id']) && !empty($a_acls[$_GET['id']])) { $id = $_GET['id']; @@ -73,6 +72,7 @@ if ($_SERVER['REQUEST_METHOD'] === 'GET') { write_config(); mark_subsystem_dirty('unbound'); } + header(url_safe('Location: /services_unbound_acls.php')); exit; } else { // transform networks into row items @@ -201,7 +201,7 @@ if (!isset($_GET['act'])) {
+ if ($act=="new" || $act=="edit"): ?> @@ -267,7 +267,7 @@ if (!isset($_GET['act'])) { } else { $acl_networks = $pconfig['row']; } - foreach($acl_networks as $item_idx => $item):?> + foreach ($acl_networks as $item_idx => $item):?> + foreach ($a_acls as $acl):?>
@@ -345,7 +345,7 @@ if (!isset($_GET['act'])) { $active_interfaces = get_configured_interface_with_descr(); } $automatic_allowed = array(); - foreach($active_interfaces as $ubif => $ifdesc) { + foreach ($active_interfaces as $ubif => $ifdesc) { $ifip = get_interface_ip($ubif); if (!empty($ifip)) { $subnet_bits = get_interface_subnet($ubif); @@ -389,7 +389,7 @@ if (!isset($_GET['act'])) {