From 1f04842feb728269d960a8a15740be5ba9ce9808 Mon Sep 17 00:00:00 2001 From: Jakob Date: Wed, 19 Feb 2020 22:20:25 +0100 Subject: [PATCH] =?UTF-8?q?=E2=80=9Ethreadr/boards/index.php=E2=80=9C=20?= =?UTF-8?q?=C3=A4ndern?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- threadr/boards/index.php | 42 ++++++++++++++++++---------------------- 1 file changed, 19 insertions(+), 23 deletions(-) diff --git a/threadr/boards/index.php b/threadr/boards/index.php index 6a530e0..9fd7824 100644 --- a/threadr/boards/index.php +++ b/threadr/boards/index.php @@ -5,31 +5,27 @@ -
-
- prepare("SELECT name FROM boards"); - $statement->execute(); + $statement = $pdo->prepare("SELECT name FROM boards"); + $statement->execute(); - echo "
    " - foreach($statement->fetchAll() as $ROW) { - echo " -
  • $ROW[name]
  • "; - } - echo "
" - } - catch(PDOException $Exception) { - $error_message = "Error: SQL error.\n" . $statement->queryString . "\n" . $statement->errorInfo()[2]; - } + echo "
    " + foreach($statement->fetchAll() as $ROW) { + echo " +
  • $ROW[name]
  • "; + } + echo "
" + } + catch(PDOException $Exception) { + $error_message = "Error: SQL error.\n" . $statement->queryString . "\n" . $statement->errorInfo()[2]; + } - $pdo = null; - ?> -
-
+ $pdo = null; + ?>