1 2 3 4 5 6 7 8 |
function wpm_add_custom_types( $query ) { if( is_category() || is_tag() && empty( $query->query_vars['suppress_filters'] ) ) { $query->set( 'post_type', array( 'post', 'case' )); return $query; } } add_filter( 'pre_get_posts', 'wpm_add_custom_types' ); |