Getting one specific value from get_children array
If you want to query by a post author , you can try the author input argument: $sub_orders = get_children( array( ‘author’ => $seller_id, ‘post_parent’ => $reservation->transaction_id, ‘post_type’ => ‘shop_order’, ‘post_status’ => array( ‘wc-pending’, ‘wc-completed’, ‘wc-processing’, ‘wc-on-hold’ ) ) ); Note that get_children() calls get_posts(), that is again a wrapper for WP_Query, so you can … Read more