I want to be able to provide links to the previos and next post from THE SAME category while the user is viewing an individual post, but I can only do that with the
next_post_link() functions, because only they support the checking parameter called
I am ok to use those two functions, but they do not have the functionality I need - the
sep parameter which serves to display text between the two links.
Here's what I currently use:
<?php previous_post_link('%link', '« Watch Previous ' . $category_name . ' Episode', TRUE); ?> --- <?php next_post_link('%link', 'Watch Next ' . $category_name . ' Episode »', TRUE); ?>
So I am using "---" as text between the two links, but when there is no next or previous post in the category, the displayed text is like this:
« Watch Previous Weeds Episode ---, thus - the unneded triple dash.