Exclude Child Posts from WP_Query

How can I exclude child posts using wp_query? Given the following architecture:

  • parent 1
    • child 1
    • child 2
  • parent 2
    • child 3
    • child 4

I’d like to only return parent 1 and parent 2, and exclude child 1, 2, 3 and 4.

Read More

I’ve searched high and low for an answer to this question. Nothing surfaces.

Related posts

Leave a Reply

1 comment