I have a front page of a site that consists of different custom post types.
To achieve this I've been using the WP_Query();
function.
In the example below, the query is used in a section and outputs the first 3 posts of the 'news' custom post type.
Is it possible to have a WP_Query where you output a certain range of posts i.e. In a different section I would like to output posts 4-6 of this same 'news' custom post type, not 1-3 (using the default published date as the criteria so it basically shows the 4th, 5th and 6th oldest posts).
Because this is dynamic content I would like it so it always shows posts 4-6 so I don't have to manually change a date range.
Any help would be amazing.
<?php
$homePageNews = new WP_Query(array(
'posts_per_page' => 3,
'post_type'=> 'news'
));
while($homePageNews->have_posts()){
$homePageNews->the_post(); ?>
// HTML OUTPUT
<?php } ?>
<?php wp_reset_postdata(); ?>