I’m trying to figure out the best way to get one “featured” headline, 100% width at the top of the TwentyTen theme.
Is there an easy way to handle this? A plugin that is not a slider. It should only show one headline and image with a link to the story and a list of the number of comments.
Thank you for your suggestions.
query_posts( array( 'showposts' => 1, 'tag' => 'featured' ) );
if( have_posts() ) : while( have_posts() ) : the_post();
<h1 class="entry-title"><a href="<?php the_permalink(); ?>" title="<?php printf( esc_attr__( 'Permalink to %s', 'twentyten' ), the_title_attribute( 'echo=0' ) ); ?>" rel="bookmark"><?php the_title(); ?></a></h1>
<a href="<?php the_permalink(); ?>" rel="bookmark"><?php the_post_thumbnail('home-featured-thumb', array('class' => 'entry-thumb')); ?></a>
<?php endwhile; endif; wp_reset_query(); ?>
I decided to paste this code into the index.php file of a child theme and it seems to work – except the featured image (thumbnail) isn’t working. At least the headline works.