• Hi, I just wondered if there is a way to set a blog post as a featured blog post to appear on my homepage, maybe there’s a checkbox for make featured in homepage or something?! at the moment (in the code below) I am just showing the last 2 blog posts

    Code to query my blog posts

    <?php query_posts('showposts=2&date=ASC'); ?>
    			<?php if (have_posts()) : while (have_posts()) : the_post(); ?>
    			<?php get_template_part( 'home', 'news' ); // Returns home-news.php) ?>
    			<?php endwhile; endif; ?>

    home-news.php page

    <li>
    	<a href="<?php the_permalink(); ?>"><h5><?php the_title(); ?></h5></a>
    	<a href="<?php the_permalink(); ?>"><span><?php echo get_the_excerpt(); ?></span></a>
    	<h6><?php the_time('j M Y') ?></h6>
    </li>

Viewing 2 replies - 1 through 2 (of 2 total)
Viewing 2 replies - 1 through 2 (of 2 total)
  • The topic ‘Featured blog to apear on homepage by checkbox?’ is closed to new replies.