summaryrefslogtreecommitdiff
path: root/dist/inc/pagination.php
diff options
context:
space:
mode:
Diffstat (limited to 'dist/inc/pagination.php')
-rw-r--r--dist/inc/pagination.php56
1 files changed, 0 insertions, 56 deletions
diff --git a/dist/inc/pagination.php b/dist/inc/pagination.php
deleted file mode 100644
index 9a6ff79..0000000
--- a/dist/inc/pagination.php
+++ /dev/null
@@ -1,56 +0,0 @@
-<?php
-/**
- * Pagination layout.
- *
- * @package understrap
- */
-
-if ( ! defined( 'ABSPATH' ) ) {
- exit; // Exit if accessed directly.
-}
-
-if ( ! function_exists ( 'understrap_pagination' ) ) {
-
- function understrap_pagination( $args = array(), $class = 'pagination' ) {
-
- if ($GLOBALS['wp_query']->max_num_pages <= 1) return;
-
- $args = wp_parse_args( $args, array(
- 'mid_size' => 2,
- 'prev_next' => true,
- 'prev_text' => __('&laquo;', 'understrap'),
- 'next_text' => __('&raquo;', 'understrap'),
- 'screen_reader_text' => __('Posts navigation', 'understrap'),
- 'type' => 'array',
- 'current' => max( 1, get_query_var('paged') ),
- ) );
-
- $links = paginate_links($args);
-
- ?>
-
- <nav aria-label="<?php echo $args['screen_reader_text']; ?>">
-
- <ul class="pagination">
-
- <?php
-
- foreach ( $links as $key => $link ) { ?>
-
- <li class="page-item <?php echo strpos( $link, 'current' ) ? 'active' : '' ?>">
-
- <?php echo str_replace( 'page-numbers', 'page-link', $link ); ?>
-
- </li>
-
- <?php } ?>
-
- </ul>
-
- </nav>
-
- <?php
- }
-}
-
-?>