WordPress Development Stack Exchange is a question and answer site for WordPress developers and administrators. Join them; it only takes a minute:

Sign up
Here's how it works:
  1. Anybody can ask a question
  2. Anybody can answer
  3. The best answers are voted up and rise to the top

I have a category page, which shows this category's subcategories.

I want in each subcategory to show its first five articles. And then provide pagination for each subcategory in order to allow user to see next/previous articles of this subcategory.

How can I do this?

share|improve this question
Not impossible, but would be extremely convoluted to implement. Could you elaborate why you want such nested pagination rather than simply linking to corresponding archive pages? – Rarst Oct 12 '12 at 13:26
My portal users need to click on a master category and the contained sub-categories are listed. Each sub-category may contain 50-100 posts. So they ask if paging on those subcategories is possible. Thanks. – p.a. Oct 13 '12 at 17:29

Possibly, try calling paginate_links in each loop either on the last iteration, or prior to making the cleanup call.

There is a chance though that it will simply attempt to paginate the current page, rather than lead to a specific archive, so it would make more sense to add a link to the relevant archive instead.

share|improve this answer

Your Answer


By posting your answer, you agree to the privacy policy and terms of service.

Not the answer you're looking for? Browse other questions tagged or ask your own question.