I'm using featured images on a WordPress site on pages (not posts). It works fine until I use query_posts
in a page template and then the header/branding img reverts to the standard images.
This is the code I'm using:
<?php
query_posts(array('category_name'=>'news-and-features', 'posts_per_page' => 2 ));
while (have_posts()) : the_post(); ?>
<div class="single-post">
<h3><a href="<?php echo get_permalink(); ?>"><?php the_title();?></a></h3>
<?php the_time('D jS M, Y') ?>
<?php the_excerpt();?>
</div>
<? endwhile; ?>
The post excerpts display fine. It's just that the query_posts
breaks the featured image.
Has anyone found this also? Or any possible solutions?
I am using a custom child theme and the above is in a template.
MTIA.