Exemplo n.º 1
0
    $guid = $_POST["Set_Guid"];
    if (isset($_POST["Set_Password"]) && $_POST["Set_Password"] !== "" && $_POST["Set_Password"] !== Null) {
        $password = hash("sha512", $_POST["Set_Password"]);
    } else {
        if (isset($_POST["Set_Disable_authentication"])) {
            $password = "";
        } else {
            $password = costant::login_password();
        }
    }
    $parameterarray = array("disable_authentication" => $disable_authentication, "user_username" => $username, "user_password" => $password, "disable_payee" => $disable_payee, "disable_category" => $disable_category, "defaultaccountname" => $default_account, "desktop_guid" => $guid);
    if (file_exists("configuration_user.php")) {
        various::update_configuration_file($parameterarray);
        header("Location: landing.php");
    } else {
        various::update_configuration_file($parameterarray);
        header("Location: guide.php");
    }
}
?>
<!DOCTYPE HTML>
<html lang="en">
    <head>
        <meta charset="utf-8" />
        <meta name="viewport" content="width=device-width, initial-scale=1.0, user-scalable=no, maximum-scale=1" />
        <meta name="apple-mobile-web-app-capable" content="yes" />
    	
        <title>Money Manager EX</title>
        <link rel="icon" href="res/favicon.ico" />
        <link rel="apple-touch-icon" href="res/apple-touch-icon.png" />
        
Exemplo n.º 2
0
 public static function to_0_9_9()
 {
     $parameterarray = array("disable_authentication" => costant::disable_authentication() ? "True" : "False", "user_username" => costant::login_username(), "user_password" => costant::login_password(), "disable_payee" => costant::disable_payee() ? "True" : "False", "disable_category" => "False", "defaultaccountname" => costant::transaction_default_account(), "desktop_guid" => costant::desktop_guid());
     various::update_configuration_file($parameterarray);
     $const_dbpath = costant::database_path();
     $db = new PDO("sqlite:{$const_dbpath}");
     $db->exec("ALTER TABLE Payee_List ADD DefCateg TEXT");
     $db->exec("ALTER TABLE Payee_List ADD DefSubCateg TEXT");
     $db->exec("UPDATE Payee_List SET DefCateg = 'None', DefSubCateg = 'None'");
     $db->exec("UPDATE New_Transaction SET Category = 'None', SubCategory = 'None'");
     $db->exec("UPDATE Parameters SET Value = '0.9.9' WHERE Parameter = 'Version';");
     $db = null;
 }