Added feedback notifications for successful edits to pages aside from users and settings (iss0000159).

This commit is contained in:
2018-06-18 15:20:24 +02:00
committed by Stefan Rohde-Enslin
parent c6f481ffcb
commit e73262a649
3 changed files with 9 additions and 1 deletions

View File

@ -51,7 +51,9 @@ if (isset($task)) {
if (!isset($id)) $id = "0";
$targetID = storePage($pages, ["title" => (string)$title, "content" => (string)$content, "higher" => $higher, "public" => (bool)$public], (int)$id);
$_SESSION["editHistory"] = ["changesStored", $translations['storedEditsToPage'] . " $title"];
header('Location: page.php?id=' . $targetID);
return;
}
@ -63,12 +65,14 @@ if (isset($task)) {
unlink(__DIR__ . "/../data/static/$id.json");
generateStaticPgCaches();
$_SESSION["editHistory"] = ["changesAborted", $translations['deletedPage'] . " $title"];
header('Location: pages.php');
return;
}
}
/*
* Output
*/