aboutsummaryrefslogtreecommitdiffstats
path: root/phpBB/phpbb/pagination.php
diff options
context:
space:
mode:
Diffstat (limited to 'phpBB/phpbb/pagination.php')
-rw-r--r--phpBB/phpbb/pagination.php14
1 files changed, 9 insertions, 5 deletions
diff --git a/phpBB/phpbb/pagination.php b/phpBB/phpbb/pagination.php
index 6a7631c89d..1d20b7f81c 100644
--- a/phpBB/phpbb/pagination.php
+++ b/phpBB/phpbb/pagination.php
@@ -1,9 +1,13 @@
<?php
/**
*
-* @package phpbb
-* @copyright (c) 2013 phpBB Group
-* @license http://opensource.org/licenses/gpl-2.0.php GNU General Public License v2
+* This file is part of the phpBB Forum Software package.
+*
+* @copyright (c) phpBB Limited <https://www.phpbb.com>
+* @license GNU General Public License, version 2 (GPL-2.0)
+*
+* For full copyright and license information, please see
+* the docs/CREDITS.txt file.
*
*/
@@ -122,8 +126,8 @@ class pagination
// determine this number. Again at most five pages? Then just display them all. More than
// five and we first (min) determine whether we'd end up listing more pages than exist.
// We then (max) ensure we're displaying the minimum number of pages.
- $start_page = ($total_pages > 5) ? min(max(1, $on_page - 3), $total_pages - 4) : 1;
- $end_page = ($total_pages > 5) ? max(min($total_pages, $on_page + 3), 5) : $total_pages;
+ $start_page = ($total_pages > 5) ? min(max(1, $on_page - 2), $total_pages - 4) : 1;
+ $end_page = ($total_pages > 5) ? max(min($total_pages, $on_page + 2), 5) : $total_pages;
}
if ($on_page != 1)