I am trying to grab the 5 most recent posts and have it exclude posts in an array that is already defined ($exclude), sticky posts and any posts that are checked off as a featured post (i.e. with the custom field "my_featured_post" set to 1)
$args = array('post__not_in' => $exclude, 'ignore_sticky_posts' => 1, 'posts_per_page' => 5, 'meta_query'=> array( array( 'key'=>'my_featured_post', 'value'=>'1', 'compare'=>'!=' ) ) ); $query = new WP_Query($args);
$args = array('post__not_in' => $exclude, 'ignore_sticky_posts' => 1, 'paged'=>1, 'posts_per_page' => 5, 'meta_key'=>'my_featured_post', 'meta_value'=>'1', 'meta_compare'=>"!=" );
Neither returned any posts. If i remove the references to meta in either query, it returns a mix of posts set as "my_featured_posts" and not set as such.
Am I going about this wrong?