diff --git a/bl-kernel/helpers/paginator.class.php b/bl-kernel/helpers/paginator.class.php index 645a0304..e7b187ac 100644 --- a/bl-kernel/helpers/paginator.class.php +++ b/bl-kernel/helpers/paginator.class.php @@ -58,6 +58,40 @@ class Paginator { return $url.'?page='.self::get('prevPage'); } + public static function urlLastPage() + { + global $Url; + + $domain = trim(DOMAIN_BASE,'/'); + $filter = trim($Url->activeFilter(), '/'); + + if(empty($filter)) { + $url = $domain.'/'.$Url->slug(); + } + else { + $url = $domain.'/'.$filter.'/'.$Url->slug(); + } + + return $url.'?page='.self::get('numberOfPosts'); + } + + public static function urlFirstPage() + { + global $Url; + + $domain = trim(DOMAIN_BASE,'/'); + $filter = trim($Url->activeFilter(), '/'); + + if(empty($filter)) { + $url = $domain.'/'.$Url->slug(); + } + else { + $url = $domain.'/'.$filter.'/'.$Url->slug(); + } + + return $url.'?page=0'; + } + public static function html($textPrevPage=false, $textNextPage=false, $showPageNumber=false) { global $Language; diff --git a/bl-languages/en_US.json b/bl-languages/en_US.json index e92c7774..f304551a 100644 --- a/bl-languages/en_US.json +++ b/bl-languages/en_US.json @@ -51,6 +51,8 @@ "themes": "Themes", "prev-page": "Prev page", "next-page": "Next page", + "first-page": "First page", + "last-page": "Last page", "configure-plugin": "Configure plugin", "confirm-delete-this-action-cannot-be-undone": "Confirm delete, this action cannot be undone.", "site-title": "Site title", diff --git a/bl-themes/log/assets/css/main.css b/bl-themes/log/assets/css/main.css index 8af48f5e..0bea930f 100644 --- a/bl-themes/log/assets/css/main.css +++ b/bl-themes/log/assets/css/main.css @@ -2271,13 +2271,50 @@ content: '\f053'; } +ul.actions.pagination .last { + text-decoration: none; + } + + ul.actions.pagination .next:after { + content: ""; + -moz-osx-font-smoothing: grayscale; + -webkit-font-smoothing: antialiased; + font-family: FontAwesome; + font-style: normal; + font-weight: normal; + text-transform: none !important; + } + + ul.actions.pagination .next:after { + content: '\f050'; + } +ul.actions.pagination .first { + text-decoration: none; + } + + ul.actions.pagination .next:after { + content: ""; + -moz-osx-font-smoothing: grayscale; + -webkit-font-smoothing: antialiased; + font-family: FontAwesome; + font-style: normal; + font-weight: normal; + text-transform: none !important; + } + + ul.actions.pagination .next:after { + content: '\f049'; + } + + @media screen and (max-width: 1280px) { ul.actions.pagination { text-align: center; } - ul.actions.pagination .next, ul.actions.pagination .previous { + ul.actions.pagination .next, ul.actions.pagination .previous, + ul.actions.pagination .last, ul.actions.pagination .first { min-width: 20em; } @@ -2285,7 +2322,8 @@ @media screen and (max-width: 736px) { - ul.actions.pagination .next, ul.actions.pagination .previous { + ul.actions.pagination .next, ul.actions.pagination .previous, + ul.actions.pagination .last, ul.actions.pagination .first { min-width: 18em; } diff --git a/bl-themes/log/php/home.php b/bl-themes/log/php/home.php index 35b7e177..8216cd6b 100644 --- a/bl-themes/log/php/home.php +++ b/bl-themes/log/php/home.php @@ -73,11 +73,18 @@ \ No newline at end of file