Custom Post Type Pagination & duplicate posts
I think the best way to implement this is to use pre_get_posts hook. Take a look at this code function customize_query( $query ) { $post = get_posts(array( ‘post_type’ => ‘projects’, ‘taxonomy’ => ‘featured’, ‘numberposts’ => 1 )); if ( $query->is_home() && $query->is_main_query() ) { $query->set( ‘post_type’, ‘projects’ ); $query->set( ‘posts_per_page’, 6 ); if($post && !empty($post)) … Read more