Is there a way to rewrite alchymyth’s solution to work with the auto excerpt (or, even better – limit the auto excerpt by characters (rather than words) at the source)?
I just dropped this into my functions.php and I now only get my custom post types showing on category requests.
function show_workshowcase( $query ) {
if ( is_category() )
$query->set( 'post_type', array( 'work_showcase' ) );
return $query;
}
add_filter( 'pre_get_posts', 'show_workshowcase' );
But, of course, standard post category requests only show the custom post type. Any ideas how I can separate the two?
Thanks Curtiss.
I would need to use a different category.php template (so as not to interfere with blog post category requests), in the same way you can have a single-{posttype}.php or archive-{posttype}.php template. However, ‘category-{posttype}.php’ is not supported.
Is there a way to achieve category-{posttype}.php?