Thank you @anlino !
For anyone looking to create similar, I achieved it with this custom code block in singular.php, between the ‘page-header’ and ‘content’:
<!-- Display posts if page name is "Featured Work" -->
<?php if ( is_page( "Featured Work" ) ) : ?>
<div class="posts" id="posts">
<?php $postslist = get_posts( array(
'order' => 'ASC',
'orderby' => 'rand',
// Display posts only in certain category option:
// 'category_name' => 'category-slug'
) );
if ( $postslist ) {
foreach ( $postslist as $post ) :
setup_postdata( $post );
get_template_part( 'content' );
endforeach;
wp_reset_postdata();
} ?>
<?php endif; ?>
</div> <!-- .posts -->
-
This reply was modified 4 years, 6 months ago by mattfrieder.