From 4a255ebe076fc0e27189a390345dbf77c881eab3 Mon Sep 17 00:00:00 2001 From: Tijn Kuyper Date: Wed, 3 Apr 2019 12:41:01 +0200 Subject: [PATCH] Make forum page navigation consistent with topic nextprev --- e107_plugins/forum/forum_viewforum.php | 3 +++ 1 file changed, 3 insertions(+) diff --git a/e107_plugins/forum/forum_viewforum.php b/e107_plugins/forum/forum_viewforum.php index d87bac7ed..132948ac6 100644 --- a/e107_plugins/forum/forum_viewforum.php +++ b/e107_plugins/forum/forum_viewforum.php @@ -1049,6 +1049,9 @@ function fpages($thread_info, $replies) $replies = (int) $replies; $postsPerPage = (int) $forum->prefs->get('postspage'); + + // Add 1 for the first post in the topic (which technically is not a reply), to make it consistent with the nextprev in the forum_viewtopic page + $replies = $replies + 1; $pages = ceil(($replies)/$postsPerPage);