How to display posts from multiple post type in random order in wordpress?
You would need two queries to achieve this. You can’t specify the limit per post type in WP_Query (without modifying the raw SQL). What you could do is simply query the posts and the photos and merge the resulting arrays: // Fetch posts $posts_query = new WP_Query( array( ‘post_type’=> ‘post’, ‘orderby’ => ‘date’, ‘posts_per_page’ => … Read more