So, I have a custom content type called “team” where I have an ACF field attached called “external” which is a checkbox. I am currently getting all the posts by passing the following arguments array to the get_post function.
$args = array(
'posts_per_page' => -1,
'offset' => 0,
'orderby' => 'menu_order',
'order' => 'ASC',
'post_type' => 'team',
'post_status' => 'publish',
);
What I’d like to do is run this in two functions checking if the field is or is not checked, essentially filtering by who is and isn’t internal. I’m not sure how to set the meta-query up for this.