Exemplo n.º 1
0
function updateUiSettings()
{
    global $cfg;
    $settings = processSettingsParams();
    saveSettings($settings);
    AuditAction($cfg["constants"]["admin"], " Updating TorrentFlux UI Settings");
    header("location: admin.php?op=uiSettings");
}
Exemplo n.º 2
0
function updateSettingsUser()
{
    global $cfg;
    $settings = processSettingsParams();
    saveUserSettings($cfg["uid"], $settings);
    AuditAction($cfg["constants"]["admin"], "updated per user settings for " . $cfg["user"]);
    header("location: profile.php");
}
Exemplo n.º 3
0
     AuditAction($cfg["constants"]["admin"], "reset personal settings for " . $cfg["user"]);
     @header("location: index.php?iid=profile");
     exit;
     //******************************************************************************
     // updateSettingsUser -- update per user settings
     //******************************************************************************
 //******************************************************************************
 // updateSettingsUser -- update per user settings
 //******************************************************************************
 case "updateSettingsUser":
     // permission
     if ($cfg["enable_personal_settings"] != 1) {
         AuditAction($cfg["constants"]["error"], "ACCESS DENIED: " . $cfg["user"] . " tried to reset personal settings");
         @error("Personal Settings are disabled. Action has been logged.", "", "");
     }
     $settings = processSettingsParams(true, true);
     saveUserSettings($cfg["uid"], $settings);
     AuditAction($cfg["constants"]["admin"], "updated personal settings for " . $cfg["user"]);
     @header("location: index.php?iid=profile");
     exit;
     //******************************************************************************
     // addCookie -- adding a Cookie Host Information
     //******************************************************************************
 //******************************************************************************
 // addCookie -- adding a Cookie Host Information
 //******************************************************************************
 case "addCookie":
     $newCookie["host"] = tfb_getRequestVar('host');
     $newCookie["data"] = tfb_getRequestVar('data');
     if (!empty($newCookie)) {
         AddCookieInfo($newCookie);
/**
 * updateFluAzuSettings
 */
function admin_updateFluAzuSettings()
{
    global $cfg;
    // FluAzu
    require_once "inc/classes/FluAzu.php";
    $message = "";
    if ($_POST["fluazu_host"] != $cfg["fluazu_host"] || $_POST["fluazu_port"] != $cfg["fluazu_port"] || $_POST["fluazu_secure"] != $cfg["fluazu_secure"] || $_POST["fluazu_user"] != $cfg["fluazu_user"] || $_POST["fluazu_pw"] != $cfg["fluazu_pw"]) {
        // fluazu Running?
        if (FluAzu::isRunning()) {
            $message = 'fluazu needs to be stopped before settings can be changed.';
        } else {
            // save settings
            $settings = processSettingsParams(false, false);
            saveSettings('tf_settings', $settings);
            $message = 'Settings changed.';
            // log
            AuditAction($cfg["constants"]["admin"], " Updating fluazu Settings");
        }
    }
    if ($message != "") {
        @header("Location: admin.php?op=fluazuSettings&m=" . urlencode($message));
    } else {
        @header("Location: admin.php?op=fluazuSettings");
    }
    exit;
}