From eb2cb4203b3f0052099773a6f91758887ed7771f Mon Sep 17 00:00:00 2001 From: lopar Date: Thu, 1 Nov 2018 02:26:30 +0200 Subject: [PATCH] Moderator options --- forum.php | 5 ++--- 1 file changed, 2 insertions(+), 3 deletions(-) diff --git a/forum.php b/forum.php index 4ae6d55..29b1f9a 100644 --- a/forum.php +++ b/forum.php @@ -365,8 +365,6 @@ if (isset($_GET['do']) && $isModerator == true) { -

Форум

-← на главную
@@ -588,7 +586,8 @@ if (isset($_GET['do']) && $isModerator == true) { $pgs = db::c()->query('SELECT count(`id`) FROM `forum` WHERE `parent` = ?i ORDER BY `fix` DESC, `updated` DESC', $_GET['conf'])->fetch_row(); $pgs = $pgs[0] / 20; $pages_str = ''; - $page = (!empty((int)$_GET['page'])) ? (((int)$_GET['page'] + 1) > $pgs ? ($pgs - 1) : (int)$_GET['page']) : 0; + if (empty($_GET['page'])) $_GET['page'] = 0; + $page = (int)$_GET['page'] ? (((int)$_GET['page'] + 1) > $pgs ? ($pgs - 1) : (int)$_GET['page']) : 0; $page = ceil($page); ?>