*** empty log message ***

svn path=/trunk/boinc/; revision=4305
This commit is contained in:
David Anderson 2004-10-08 19:57:20 +00:00
parent 615cabb8df
commit 79d3c7d3c4
2 changed files with 28 additions and 8 deletions

View File

@ -18179,3 +18179,9 @@ David 7 Oct 2004
py/Boinc/
db_base.py
David 8 Oct 2004
- Add confirm before delete prefs
html/user/
prefs_remove.php

View File

@ -10,16 +10,30 @@ $user = get_logged_in_user();
$subset = $_GET["subset"];
$venue = $_GET["venue"];
$confirmed = $_GET["confirmed"];
if ($subset == "global") {
$main_prefs = prefs_parse_global($user->global_prefs);
$main_prefs->$venue = null;
global_prefs_update($user, $main_prefs);
if ($confirmed) {
if ($subset == "global") {
$main_prefs = prefs_parse_global($user->global_prefs);
$main_prefs->$venue = null;
global_prefs_update($user, $main_prefs);
} else {
$main_prefs = prefs_parse_project($user->project_prefs);
$main_prefs->$venue = null;
project_prefs_update($user, $main_prefs);
}
Header("Location: prefs.php?subset=$subset");
} else {
$main_prefs = prefs_parse_project($user->project_prefs);
$main_prefs->$venue = null;
project_prefs_update($user, $main_prefs);
page_head("Confirm delete preferences");
echo "
<p>
Are you sure you want to delete your separate ", subset_name($subset),
" preferences for $venue?
<br><br>
<a href=prefs_remove.php?subset=$subset&venue=$venue&confirmed=yes>Yes</a>
| <a href=prefs.php?subset=$subset>Cancel</a>
";
page_tail();
}
Header("Location: prefs.php?subset=$subset");
?>