WordPress.org

Ready to get started?Download WordPress

Forums

Hard exclude of categories in next_post_link (1 post)

  1. Sean
    Member
    Posted 3 years ago #

    Hi, in single.php, I'm trying to exclude a category in next_post_link:

    <?php next_post_link('%link', '%title &rarr;', TRUE, '4'); ?>

    But this won't work if the category specified is a sibling category (ie is also in the same parent category as the current post). Is there any way to tell WordPress that exclude means exclude absolutely?

Topic Closed

This topic has been closed to new replies.

About this Topic