Limiting blog pagination

Hi there. I created a blog page and set up a Condition to limit the posts displayed that were published after a certain date. Posts are limited to 10 per page. In total there are 20 posts which results in a total of two pages, however the pagination element has a count of nine pages so every page displayed after 2 is empty.
Is there way for the pagination to only display pages with blog posts on and not to display empty pages?

Hello Alan,

Thanks for writing in!

I have seen this condition in your Looper Consumer:

This will not work because it will only hide away the post item returned by the WordPress loop. To do it properly, you will have to modify the WordPress query before it returns the items in the loop for the shop index. Please check out this article instead:

If you do not want to display certain post items, it is best that you archive them instead:

Best Regards.

Thanks so much. I used the Archive method which produces precisely the results that I want.

You are most welcome, Alan.

This topic was automatically closed 10 days after the last reply. New replies are no longer allowed.