All I want to do is link to the next post in the same category, and for the life of me I can't see what's wrong with my code. Does in_same_term work for everyone else?
<?php $prev_post = get_adjacent_post( true, '18 and 20 and 10 and 21 and 19 and 22 and 17', true, 'portcats' ); ?> <?php if ( !empty( $prev_post ) ): ?> <?php // get the id of the category you just came from $term_id = $_REQUEST['cat']; ?> <a href="<?php echo $baseurl . '/portfolio/' . $prev_post->post_name; ?>/?cat=<?php echo $term_id; ?>"><span class="plain-text">Previous</span> PROJECT</a> <?php endif; ?>