From bc5182c179e6259fce004322898233391ab8814e Mon Sep 17 00:00:00 2001 From: Jakob Date: Wed, 4 Mar 2020 11:01:05 +0100 Subject: [PATCH] something's broken --- threadr/boards/index.php | 4 +--- 1 file changed, 1 insertion(+), 3 deletions(-) diff --git a/threadr/boards/index.php b/threadr/boards/index.php index 4aa85a6..1154e54 100644 --- a/threadr/boards/index.php +++ b/threadr/boards/index.php @@ -25,9 +25,8 @@ $navbar="boards"; $pdo = new PDO('mysql:host=localhost;dbname=web', 'webstuff', 'Schei// auf Pa$$w0rter!'); $error = false; $error_message = ""; - echo "

Public boards:

" if (!$error) { - $statement = $pdo->prepare("SELECT * FROM boards ORDER BY id asc"); + $statement = $pdo->prepare("SELECT * FROM boards WHERE public = '1' ORDER BY id asc"); $statement->execute(); foreach($statement->fetchAll() as $ROW) { echo "
  • $ROW[name]
  • "; @@ -37,7 +36,6 @@ $navbar="boards"; $error_message = "Error: SQL error.\n" . $statement->queryString . "\n" . $statement->errorInfo()[2]; } if ($login) { - echo "

    Private boards:

    " if (!$error) { $statement = $pdo->prepare("SELECT * FROM boards WHERE public='0' ORDER BY id asc"); $statement->execute();