More Projects sorted by project category instead of post date
-
I’d like the “More Projects” (at the bottom of individual project posts) to navigate to the previous and next project within the same project category. The default is to navigate by project post date.
I believe that template-tags.php is the file to edit, but I’m not sure how to adjust the code. Or if this is possible. Here’s a link to my dev site. Thanks for looking.
function sketch_portfolio_pagination() { global $post; $pagination_posts = array(); $pagination_posts['previous'] = get_adjacent_post( false, '', true ); $pagination_posts['current'] = get_post(); $pagination_posts['next'] = get_adjacent_post( false, '', false ); if ( ! $pagination_posts['previous'] && ! $pagination_posts['next'] ) return false; ?>
Viewing 2 replies - 1 through 2 (of 2 total)
Viewing 2 replies - 1 through 2 (of 2 total)
- The topic ‘More Projects sorted by project category instead of post date’ is closed to new replies.