I altered the following code from Ashfame:
add_action('pre_get_posts', 'block_cat_query' );
function block_cat_query() {
global $wp_query;
if( is_home() || is_search() || is_tag() ) {
$wp_query->query_vars['cat'] = '3';
}
}
This code DOES work to filter posts from category #3 only on the home, search and tag pages.
However, I am utilizing
<?php single_tag_title(); ?>
in my header.php file and on specific tag pages, the tag title is not showing up. The page is instead showing the category title. This is only happening with this function in place, so I'm trying to figure out if there is another way of writing the function above that does not effect the use of <?php single_tag_title(); ?>
on tag pages.