• Resolved adambhuffman

    (@adambhuffman)


    I love the featured post slider and would like to see if it is possible to also use Pages as “featured posts”. Thanks!

Viewing 2 replies - 1 through 2 (of 2 total)
  • Hi Adam! Currently not possible with the standard features. Not entirely sure what is best way to approach this, but:

    The place to edit would be /inc/featured.php with a child theme. Where you see:

    <?php while ( $featured->have_posts() ): $featured->the_post(); ?>
    <li>
    <?php get_template_part('content-featured'); ?>
    </li>
    <?php endwhile; ?>

    You can either add a new WP_Query after it, or modify the existing WP_Query with the page IDs you wish to list.

    Another way is to add the pages you want is to simply do it the static way – by adding the links/images and content directly into the file as HTML. You would then use content-feauted.php as base for each <li> item, to get it as same style as the other post entries.

    For non-static html, “WP_Query with pages” may give some pointers in the right direction.

    Function reference for WP_Query here.

    How to use a child theme here. Sample child theme for Hueman download here.

    Sorry for a not-so-clear answer.

    Thread Starter adambhuffman

    (@adambhuffman)

    That’s about as clear an answer as I could hope for. I think that integrating the featured slider to include features like this in future releases would be huge. I know I would personally be donating a healthy amount if that ever happened.

Viewing 2 replies - 1 through 2 (of 2 total)

The topic ‘Using a Page as a "Featured Post"’ is closed to new replies.