Custom WordPress theme not displaying posts from category
I thought WordPress was supposed to do all the heavy lifting as far as filtering by categories, tags, authors, etc. It does. Which is why you shouldn’t have done this: $category = get_category( get_query_var( ‘cat’ ) ); $cat_id = $category->cat_ID; $loop = new WP_Query( array( ‘cat’ => $cat_id ) ); In the main template files … Read more