I'm trying to get all post except particular category this works fine but it cause the pagination button/link to render the same posts again on page 2, 3, 4 and so on not rendering the older post. Here is how I am trying to exclude a particular category
This excludes the category but prevents pagination buttons/link from showing older posts, instead it shows the same first 5 posts as on page 1.
I tried moving the category exclusion bit into the
<?php if ( have_posts('cat=-22') ) : ?>
line but this doesn't change anything.
I'm trying to do this on the
I've also tried excluding the category by its name and I get the same results.