prepare(' UPDATE experiences SET title = :title, xptype = :xptype, tags = :tags, description = :description, duration = :duration, image_url = :image_url WHERE id = :id '); $stmt->bindValue(':title', $title, PDO::PARAM_STR); $stmt->bindValue(':xptype', $xptype, PDO::PARAM_STR); $stmt->bindValue(':tags', $tags, PDO::PARAM_STR); $stmt->bindValue(':description', $description, PDO::PARAM_STR); $stmt->bindValue(':duration', $duration, PDO::PARAM_STR); $stmt->bindValue(':image_url', $imageurl, PDO::PARAM_STR); $stmt->bindValue(':id', $id, PDO::PARAM_INT); $stmt->execute(); // Sinon on renvoie l'erreur } catch (PDOException $e) { die("Erreur lors de la modification de l experience :" . $e->getMessage()); } // On renvoie l'utilisateur sur admin.php header('Location: ../pages/admin.php'); exit;