array( 'href' => array(), 'title' => array(), 'class' => array(), 'target' => array() ), 'span' => array( 'class' => array(), ) ); if ( $type == "archive" ) { $paginate_links = paginate_links( array( 'base' => str_replace( $big, '%#%', esc_url( get_pagenum_link( $big ) ) ), 'format' => '?paged=%#%', 'prev_text' => esc_html('Prev','sheeba-lite'), 'next_text' => esc_html('Next','sheeba-lite'), 'current' => max( 1, get_query_var('paged') ), 'total' => $wp_query->max_num_pages, 'add_args' => false, )); } else if ( $type == "home" ) { $total = $wp_query->max_num_pages ; $paginate_links = paginate_links( array( 'base' => str_replace( $big, '%#%', esc_url( get_pagenum_link( $big ) ) ), 'format' => '?paged=%#%', 'prev_text' => esc_html('Prev','sheeba-lite'), 'next_text' => esc_html('Next','sheeba-lite'), 'current' => max( 1, get_query_var('paged') ), 'total' => $total, 'add_args' => false, )); } else if ( $type == "page" ) { $args = array('post_type' => 'post', 'paged' => sheeba_lite_paged(), 'posts_per_page' => get_option('posts_per_page')); $query = new WP_Query( $args ); $paginate_links = paginate_links( array( 'base' => str_replace( $big, '%#%', esc_url( get_pagenum_link( $big ) ) ), 'format' => '?paged=%#%', 'prev_text' => esc_html('Prev','sheeba-lite'), 'next_text' => esc_html('Next','sheeba-lite'), 'current' => sheeba_lite_paged(), 'total' => $query->max_num_pages , 'add_args' => false, )); } if (!empty($paginate_links)) echo '
' . wp_kses($paginate_links, $allowed) .'
'; } add_action( 'sheeba_lite_pagination', 'sheeba_lite_pagination_function' ); } ?>