If you want to keep your next posts and previous posts within the same category within the Hybrid theme framework you need to copy the `navigation-links.php` over to your child theme and edit like this.
‘‘
original
<div class="navigation-links">
<?php previous_post_link( '<span class="previous">%link</span>', __( '« Previous', 'hybrid' ) ); ?>
<?php next_post_link( '<span class="next">%link</span>', __( 'Next »', 'hybrid' ) ); ?></div>
<!-- .navigation-links --></pre>
You need to add in ‘TRUE’ to make WordPress only show the next/previous posts link within the same category, this can also be override if you supply a CAT id
<div class="navigation-links">
<?php previous_post_link( '<span class="previous">%link</span>', __( '« Previous', 'hybrid'),'TRUE' ); ?>
<?php next_post_link('<span class="next">%link</span>', __( 'Next »', 'hybrid' ),'TRUE'); ?></div>
<!-- .navigation-links --></pre>
See more from WordPress Docs…





Recent discussions