summaryrefslogtreecommitdiffstats
path: root/usr/local
diff options
context:
space:
mode:
authorScott Ullrich <sullrich@pfsense.org>2005-06-27 21:17:38 +0000
committerScott Ullrich <sullrich@pfsense.org>2005-06-27 21:17:38 +0000
commit1f2761383b5c8a01bfaf908bc21b6a2c36490452 (patch)
tree4703dd4e22b37e2cf870d1cbb680aa8c454a74e2 /usr/local
parent7dc22ace8a9b9259131d2f93a410519aab2f4373 (diff)
downloadpfsense-1f2761383b5c8a01bfaf908bc21b6a2c36490452.zip
pfsense-1f2761383b5c8a01bfaf908bc21b6a2c36490452.tar.gz
Correctly delete multiple lines at once. And leave the X on the side for the scrolling wusses.
Diffstat (limited to 'usr/local')
-rwxr-xr-xusr/local/www/firewall_shaper.php24
1 files changed, 15 insertions, 9 deletions
diff --git a/usr/local/www/firewall_shaper.php b/usr/local/www/firewall_shaper.php
index 19ae4a6..d247da0 100755
--- a/usr/local/www/firewall_shaper.php
+++ b/usr/local/www/firewall_shaper.php
@@ -91,15 +91,21 @@ if ($_POST) {
}
}
-if ($_GET['act'] == "del") {
- if ($a_shaper[$_GET['id']]) {
- unset($a_shaper[$_GET['id']]);
- write_config();
- touch($d_shaperconfdirty_path);
- header("Location: firewall_shaper.php");
- exit;
- }
-} else if ($_GET['act'] == "down") {
+if (isset($_POST['del_x'])) {
+ /* delete selected rules */
+ if (is_array($_POST['rule']) && count($_POST['rule'])) {
+ foreach ($_POST['rule'] as $rulei) {
+ unset($a_shaper[$rulei]);
+ }
+ write_config();
+ touch($d_natconfdirty_path);
+ header("Location: firewall_shaper.php");
+ exit;
+ }
+}
+
+
+if ($_GET['act'] == "down") {
if ($a_shaper[$_GET['id']] && $a_shaper[$_GET['id']+1]) {
$tmp = $a_shaper[$_GET['id']+1];
$a_shaper[$_GET['id']+1] = $a_shaper[$_GET['id']];
OpenPOWER on IntegriCloud