diff options
Diffstat (limited to 'core/include/page')
-rw-r--r-- | core/include/page/list.php | 5 |
1 files changed, 4 insertions, 1 deletions
diff --git a/core/include/page/list.php b/core/include/page/list.php index 25409e5..f80c461 100644 --- a/core/include/page/list.php +++ b/core/include/page/list.php @@ -5,13 +5,16 @@ $Database = Application::getDatabase(); $Language = Application::getLanguage(); +#=============================================================================== +# Pagination +#=============================================================================== $site_size = Application::get('PAGE.LIST_SIZE'); $site_sort = Application::get('PAGE.LIST_SORT'); $lastSite = ceil($Database->query(sprintf('SELECT COUNT(id) FROM %s', Page\Attribute::TABLE))->fetchColumn() / $site_size); $currentSite = HTTP::GET('site') ?? 1; -$currentSite = abs(intval($currentSite)); +$currentSite = intval($currentSite); if($currentSite < 1 OR ($currentSite > $lastSite AND $lastSite > 0)) { Application::error404(); |