Forums Forums Search & Filter Pro First post always added to the bottom of search results

Viewing 10 posts - 1 through 10 (of 10 total)
  • Anonymous
    #265449

    We have a filter set up which is placed in the sidebar. It filters posts by two drop-down filters (an AND relationship), displaying results as Post Type Archive. The filter has a submit and reset button. Post counts are displayed for both filter fields.

    The results initially load correctly with the correctly filtered posts, but when we scroll to the bottom of the list, our first post is added to the bottom of the filtered posts (it appears when the scroll reaches the bottom of the list). It’s always the first post, whether or not it already appears further up the filtered list.

    Results are loaded via Ajax, but disabling this does not change the problem. Infinite scroll is disabled.

    Trevor
    #265458

    Are you able to send me a live link/URL to your search page so I can take a look?

    Anonymous
    #265462
    This reply has been marked as private.
    Anonymous
    #265477

    I hope you could see the previous response – it’s private because there’s password details in it.

    Having experimented a bit more, it seems it might be related to the ‘AND’ query. I’ve now added a third filter field and it is now adding the first *two* posts to the end of every search result (including unfiltered, interestingly).

    Trevor
    #265673

    I can’t see anything wrong with the form, except, the Ajax Container looks like it needs to be changed to:

    .blog-posts-wrap

    It is currently set to #main (which is our – and the WordPress – default).

    Anonymous
    #266445

    Thanks, I have updated that but the problem persists – the first two posts are added on to the bottom of every query when I scroll to the bottom of the list.

    I wonder if it’s a clash with the theme template, but it’s beyond my WordPress competency level to figure that out unfortunately.

    Trevor
    #266565
    This reply has been marked as private.
    Anonymous
    #267131
    This reply has been marked as private.
    Trevor
    #267265

    Looking at it in some detail, it looks like your theme Post Archive template has its own Infinite Scroll in place, as the form for that page is set to Normal Pagination, which the page ignores. But, your theme is a framework type theme, so, instead of using a single template for the page, it calls many (a LOT of) PHP files, so hooking in to that would be very difficult.

    For now, the Shortcode method is the simplest solution, short of installing a page builder plugin that we support (like Elementor Pro).

    Do let me know if we can close this thread for now?

    Anonymous
    #267280

    Thank you, the shortcode is working well and I understand why we weren’t able to get things working the other way. You’ve been very helpful. Please do close the thread.

Viewing 10 posts - 1 through 10 (of 10 total)