Example #1
0
        if ($mode == "on" and $sgconf->squidGuardConf["acl"]["{$group}"]["mode"] == "on") {
            $mode = "off";
        }
        write_acl_command($group, $mode);
        echo "Switch {$group} to {$mode}<br>\n";
        $changes = true;
    } else {
        echo "Error unknown group:'{$group}'<br>\n";
    }
}
if (isset($_POST["mode"]) and isset($_POST["domains_onplus"])) {
    if ($_POST["mode"] == "onplus") {
        //Any Changes?
        if ($_POST["domains_onplus"] != $sgconf->squidGuardOnplusDomains) {
            //What Changes?
            $changes = $sgconf->compare_domains_onplus($_POST["domains_onplus"]);
            write_domains_command("onplus", $changes["add"], $changes["remove"]);
            echo "<br>" . $changes["msg"];
            $changes = true;
        } else {
            if ($debug > 2) {
                echo "OnplusDomains: no changees<br>\n";
            }
        }
    }
}
if (isset($_POST["mode"]) and isset($_POST["domains_only"])) {
    if ($_POST["mode"] == "only") {
        //Any Changes?
        if ($_POST["domains_only"] != $sgconf->squidGuardOnlyDomains) {
            //What Changes?