Trying to WP_Query a category
You are using WP_Query incorrectly: you need to be calling the have_posts() and the_post() functions as methods of your $query variable: <?php if (have_posts()) : while (have_posts()) : the_post(); ?> Becomes: <?php if ( $query->have_posts() ) : while ( $query->have_posts() ) : $query->the_post(); ?> You should also call wp_reset_postdata(); after the query loop is finished. … Read more