From ed376bd4dad27dd887120c1a7b67bae13bf06654 Mon Sep 17 00:00:00 2001 From: "Igor Barkov [iwork]" Date: Wed, 31 Oct 2018 19:38:12 +0200 Subject: [PATCH] Remove notices --- forum.php | 3 +++ 1 file changed, 3 insertions(+) diff --git a/forum.php b/forum.php index 2d04c13..2442614 100644 --- a/forum.php +++ b/forum.php @@ -553,6 +553,8 @@ if (isset($_GET['topic']) && is_numeric($_GET['topic']) && $_GET['topic'] == 228 $sort_type = 'DESC'; } + if (empty($_GET['page'])) $_GET['page'] = ""; + #$data = mysql_query("SELECT * FROM `forum` WHERE `parent` = '" . mysql_real_escape_string($_GET['topic']) . "' ORDER by `id` {$sort_type} LIMIT " . (int)($_GET['page'] * 20) . ",20"); $data = db::c()->query('SELECT * FROM `forum` WHERE `parent` = "?s" ORDER BY "?s" LIMIT ?i,20', $_GET['topic'], $sort_type, ($_GET['page'] * 20)); while ($row = $data->fetch_assoc()) { @@ -596,6 +598,7 @@ if (isset($_GET['topic']) && is_numeric($_GET['topic']) && $_GET['topic'] == 228 if (($closed == 1 && $_GET['topic'] != 228043095)) { echo "
" . $closepal . "


"; } else { + if (empty($_GET['baned'])) $_GET['baned'] = 0; if ($user['align'] == 4 && $_GET['conf'] != 23) { $error = "

Персонажам со склонностью хаос запрещено писать на этом форуме!

"; } elseif ($user['baned'] == 1) {