summaryrefslogtreecommitdiffstats
path: root/usr/local/www/system_groupmanager.php
diff options
context:
space:
mode:
authorScott Ullrich <sullrich@pfsense.org>2008-02-20 00:31:04 +0000
committerScott Ullrich <sullrich@pfsense.org>2008-02-20 00:31:04 +0000
commit02aee0690eb239a8f97c9eaab82037a0b5323c35 (patch)
treeceaf9cd937af50094aa08a7210974c6d4893568c /usr/local/www/system_groupmanager.php
parent4f7c3882123f394ddf2050c8820c345ece68303a (diff)
downloadpfsense-02aee0690eb239a8f97c9eaab82037a0b5323c35.zip
pfsense-02aee0690eb239a8f97c9eaab82037a0b5323c35.tar.gz
Correctly save pages.
Diffstat (limited to 'usr/local/www/system_groupmanager.php')
-rw-r--r--usr/local/www/system_groupmanager.php9
1 files changed, 7 insertions, 2 deletions
diff --git a/usr/local/www/system_groupmanager.php b/usr/local/www/system_groupmanager.php
index 2660297..215d232 100644
--- a/usr/local/www/system_groupmanager.php
+++ b/usr/local/www/system_groupmanager.php
@@ -257,12 +257,17 @@ if ($_POST) {
if (isset($id) && $a_group[$id])
$group = $a_group[$id];
+ if($id)
+ unset($a_group[$id]);
+
$group['name'] = $_POST['groupname'];
$group['description'] = $_POST['description'];
unset($group['pages']);
foreach ($pages as $fname => $title) {
$identifier = str_replace('.php','',$fname);
- $group['pages'][] = $fname;
+ if ($_POST[$identifier] == 'yes') {
+ $group['pages'][] = $fname;
+ }
}
if (isset($id) && $a_group[$id])
@@ -370,7 +375,7 @@ if($_GET['act']=="new" || $_GET['act']=="edit"){
</tr>
<?php
foreach ($pages as $fname => $title) {
- $identifier = str_replace('.php','',$fname);
+ $identifier = str_replace('.php','',$fname);x
?>
<tr><td class="listlr">
<input class="check" name="<?=$identifier?>" type="checkbox" id="<?=$identifier?>" value="yes" <?php if (in_array($fname,$pconfig['pages'])) echo "checked"; ?>></td>
OpenPOWER on IntegriCloud