Support Forums

Looking for support? You can access the support system via your account.

Forums Forums Search & Filter Pro Pagination Problems

Tagged: 

Viewing 10 posts - 1 through 10 (of 23 total)
  • DeAnne Curran
    #38724

    I think I am having a similar issue as this ticket: https://support.searchandfilter.com/forums/topic/pagination-alwaus-return-to-page-1/. My pagination is working correctly from this page: http://67.227.198.26/~necleanenergy/residential/photos/. However as soon as I’ve filtered the results the pagination never changes from page 1.

    I have the following checked:Load results using Ajax? , Make searches bookmarkable?, Only use Ajax on the results page?. Results Container is .photo-grid, which includes the results and the pagination section. The Pagination selector is .page-numbers a.

    This is nav code in my functions file:
    function bones_page_navi() {
    global $wp_query;
    $bignum = 999999999;
    if ( $wp_query->max_num_pages <= 1 )
    return;
    echo ‘<nav class=”pagination”>’;
    echo paginate_links( array(
    ‘base’ => str_replace( $bignum, ‘%#%’, esc_url( get_pagenum_link($bignum) ) ),
    ‘format’ => ”,
    ‘current’ => max( 1, $wp_query->query_vars[‘paged’] ),
    ‘total’ => $wp_query->max_num_pages,
    ‘prev_text’ => ‘<‘,
    ‘next_text’ => ‘>’,
    ‘type’ => ‘list’,
    ‘end_size’ => 3,
    ‘mid_size’ => 3
    ) );
    echo ‘</nav>’;

    Can you help me to correct this?

    Ross Moderator
    #38913

    Hey DeAnne

    First, just for testing, can you disable ajax?

    Then check pagination again, does it work?

    If not, there can sometimes be an issue with pagination.

    There are several WP functions for getting pagination, so if one is not working, its worth trying another – in case there is a conflict with something in your setup.

    Can you tell me, under the “display results” tab, what “display method” are you using?

    Can you test out the other WP pagination functions?

    the_posts_pagination
    next_posts_link | previous_posts_link

    Thanks

    DeAnne Curran
    #38979

    I have tried with ajax disabled and have the same results.

    Under the “display results” tab, I have “Post Type Archiveā€ selected under “Display Results Method”.

    I tried just adding the next_posts_link | previous_posts_link code to the archive template and it seems like it updates the URL to include _paged=2, even after filtering the results, how ever I can see some of the results on page 2 are repeated from page 1. So it seems like the results aren’t actually being paginated.

    DeAnne Curran
    #38980

    I believe the reason that some of the results where repeating was because we had Default Sort Order set to Random. I assume then this affects the pagination? Can you confirm?

    Can you also help trouble shoot why the pagination would work with a non filtered page: http://67.227.198.26/~necleanenergy/residential/photos/ vs not work with a filtered page http://67.227.198.26/~necleanenergy/residential/photos/?_sft_panel_location=ground&_sfm_monthly_production=0%205000, although they are using the same archive template.

    DeAnne Curran
    #39992

    We are really eager to launch this site and can’t until we have this resolved. Can you confirm you are looking into this? It has been almost two weeks since I asked this.

    Ross Moderator
    #39993

    Hey DeAnne

    I’ve literally just pulled up this ticket 30 mins ago – apologies it seemed to have slipped through.

    Can you provide admin details and I’ll take a good look?

    I think you need to update the pagination in your template to use – the_posts_pagination – which I’ll be able to help with.

    Thanks

    DeAnne Curran
    #39995
    This reply has been marked as private.
    DeAnne Curran
    #39996
    This reply has been marked as private.
    DeAnne Curran
    #39997
    This reply has been marked as private.
    Ross Moderator
    #40000
    This reply has been marked as private.
Viewing 10 posts - 1 through 10 (of 23 total)

You must be logged in to reply to this topic.