bugfix_updateArticle_missingID & updateArticle Leerzeichen im content #28
@@ -71,6 +71,7 @@ include_once 'php/controller/showArticle-controller.php';
|
||||
if (isset($title) && !empty($title)){echo htmlspecialchars($title);
|
||||
}elseif (isset($_SESSION['old_title']) && !empty($_SESSION['old_title'])){
|
||||
echo htmlspecialchars($_SESSION['old_title']);
|
||||
unset($_SESSION['old_title']);
|
||||
}
|
||||
|
||||
?>"
|
||||
@@ -80,6 +81,7 @@ include_once 'php/controller/showArticle-controller.php';
|
||||
if (isset($content) && !empty($content)){echo htmlspecialchars($content);
|
||||
}elseif (isset($_SESSION['old_content']) && !empty($_SESSION['old_content'])){
|
||||
echo htmlspecialchars($_SESSION['old_content']);
|
||||
unset($_SESSION['old_content']);
|
||||
}
|
||||
?>
|
||||
</textarea>
|
||||
@@ -144,6 +146,7 @@ include_once 'php/controller/showArticle-controller.php';
|
||||
if (isset($tags) && !empty($tags)){echo htmlspecialchars($tags);
|
||||
} elseif (isset($_SESSION['old_tags']) && !empty($_SESSION['old_tags'])){
|
||||
echo htmlspecialchars($_SESSION['old_tags']);
|
||||
unset($_SESSION['old_tags']);
|
||||
}
|
||||
?>"
|
||||
placeholder="z.B. Technik, IT (mit Komma trennen)">
|
||||
|
||||
@@ -87,10 +87,6 @@ if ($_SERVER["REQUEST_METHOD"] === "POST") {
|
||||
exit();
|
||||
}
|
||||
$_SESSION["message"] = "article_updated";
|
||||
unset($_SESSION['old_title']);
|
||||
unset($_SESSION['old_content']);
|
||||
unset($_SESSION['old_category']);
|
||||
unset($_SESSION['old_tags']);
|
||||
// Weiterleitung zur Homepage
|
||||
header("location: ../../index.php?pfad=showArticle&id=$id");
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user