Paginate through a category in a page
-
I had originally set up my menu to set categories, but that limits my use of categories to the menu structure.
Ideally what I’d prefer to do is used page templates.
So I create a new page template ‘page-for-cat.php’ and name the template ‘page of category’.
I add in this query to the page
<?php query_posts('category_name=my-cat'); while (have_posts()) : the_post(); the_content(); endwhile; ?>
I then make a new page in wordpress and set the page template to ‘page of category’. I call the page ‘Test page’.
I then add that ‘Test Page’ wordpress page to the menu structure.
So far, so good…
What I can’t get to work is the pagination to previous and next pages to work with this set up.
Where am I going wrong, hav I missed something?
Thanks
- The topic ‘Paginate through a category in a page’ is closed to new replies.