Custom query getting overwritten. Possible to by past Guest Author?

[ad_1]

Hello…

I have a custom query that I’m writing that is pulling posts that have a meta value set to show up in a featured box on the theme I’m building. However, the Guest Author plugin is over riding my meta_query condition. Is there a way,without deactivating the plugin, to tell it not to run for a specific query or tell it not to run on a specific page? Here’s the query that I’m trying to get to return a single post ID where the editor has checked off that it should show up in the call out box on the sites’ home page. Here’s the bit of code that I’m using to grab a postID . This is wrapped in a foreach statement where I’m processing all authors that have a title set.

$posts = new WP_Query( array(						    		'posts_per_page' => 1,
'author' => $user->ID,
'meta_query' => array(
array(
'key' => 'dm_show_in_editorial_callout_box',
'value' => 'yes',
)),
'no_found_rows' => true) );
					
					

 

This site will teach you how to build a WordPress website for beginners. We will cover everything from installing WordPress to adding pages, posts, and images to your site. You will learn how to customize your site with themes and plugins, as well as how to market your site online.

Buy WordPress Transfer