hi
i need to show the last post thumbnail only
i had the code but im now looking for code to get image
i need to place the image on the top

<ul>
<?php $recent = new WP_Query("cat=1&showposts=10"); while($recent->have_posts()) : $recent->the_post();?>
<li><a href="<?php the_permalink() ?>" rel="bookmark">
<?php the_title(); ?>
</a></li>
<?php endwhile; ?>
<?php wp_reset_query(); ?>
</ul>

To get the featured image, you can use the following code:

<?php if(has_post_thumbnail()): ?>
    <div class="image">
        <?php the_post_thumbnail(); ?>
    </div>
<?php endif; ?>
Be a part of the DaniWeb community

We're a friendly, industry-focused community of developers, IT pros, digital marketers, and technology enthusiasts meeting, networking, learning, and sharing knowledge.