From 52c5c6ca413473cddd0756b69da741305d946491 Mon Sep 17 00:00:00 2001 From: Jan BELLON Date: Tue, 12 Mar 2024 13:22:04 +0000 Subject: [PATCH] Update file editpage.php --- html/editpage.php | 5 ++--- 1 file changed, 2 insertions(+), 3 deletions(-) diff --git a/html/editpage.php b/html/editpage.php index 935709f3..5f1cb6c9 100644 --- a/html/editpage.php +++ b/html/editpage.php @@ -94,13 +94,12 @@ if(isset($fichier)) { if(isset($_POST['page-content'])) { file_put_contents($fichier, nl2br($_POST['page-content'])); } - if(isset($_POST['article-classification']) && isset($_POST['article-image']) && isset($_POST['article-resume']) && isset($_GET['article'])) { + if(isset($_POST['article-classification']) && isset($_POST['article-resume']) && isset($_GET['article'])) { $bdd = connect($dbhost, $dbname, $dbuser, $dbpass); - $req = $bdd->prepare("UPDATE articles SET classification = :classification, titre = :titre, image = :image, resume = :resume WHERE ID = :article AND auteur = :user_id"); + $req = $bdd->prepare("UPDATE articles SET classification = :classification, titre = :titre, resume = :resume WHERE ID = :article AND auteur = :user_id"); $req->bindParam(':classification', $_POST['article-classification']); $req->bindParam(':titre', htmlspecialchars($_POST['article-titre'])); - $req->bindParam(':image', htmlspecialchars($_POST['article-image'])); $req->bindParam(':resume', nl2br($_POST['article-resume'])); $req->bindParam(':article', $_GET['article']); $req->bindParam(':user_id', $_SESSION['userid']);