WordPress loop to pull 4 pages/posts by ID

Im trying to create a wordpress loop which pulls out 4 specific pages/posts by ID (excepts to display a teaser). The main issue is they are located in 3 different post types: ‘post’, ‘training’, ‘page’.

So far i have rewrote this code 3 times, its nearly there but not quite right.

` array( ‘post’, ‘training’, ‘page’ ),
‘post__in’ => $ids,
‘posts_per_page’ => 1)
);

if (have_posts()) :
?> `

Can anyone give me a pointer into what is going wrong?

Thank you

Read more here: WordPress loop to pull 4 pages/posts by ID

Leave a Reply

Your email address will not be published. Required fields are marked *