Pull any post or page in the middle of your query without affecting the query

Very simple. This is an example to pull your self in a loop and get out in the middle of another query.

// specific post ID you want to pull
$post = get_post(86); 
setup_postdata( $post );

	echo get_the_title();

wp_reset_postdata();

 

Leave a Reply

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

19 + = 20