From 82e100640c89e7b8ab6914c7fd811b87cec759e1 Mon Sep 17 00:00:00 2001 From: Jan BELLON Date: Fri, 8 Mar 2024 15:58:47 +0000 Subject: [PATCH] Update file news.php --- html/news.php | 12 +++++++----- 1 file changed, 7 insertions(+), 5 deletions(-) diff --git a/html/news.php b/html/news.php index 14b80835..ea835268 100644 --- a/html/news.php +++ b/html/news.php @@ -76,11 +76,13 @@ if (filter_var($_GET['article'], FILTER_VALIDATE_INT)) { $resultat = $req->fetchAll(PDO::FETCH_ASSOC); if ($resultat) { - $date = strtotime($row['date']); - echo "

"; - echo ""; - echo "
" . $row['titre'] . "
"; - echo "
"; + foreach($resultat as $row) { + $date = strtotime($row['date']); + echo "

"; + echo ""; + echo "
" . $row['titre'] . "
"; + echo "
"; + } } } ?>