Is it possible to make it work with get_posts()
Opened this issue · 0 comments
webdados commented
Is your enhancement related to a problem? Please describe.
First of all, thanks for sharing this.
The 'relationship_query' argument on queries currently only work for WP_Query
and not for get_posts()
.
Is there an underlying reason for this?
While we can easily use WP_Query
on our own developments, I'm now in a situation where I need to hook into other plugin queries, and manipulate them to return only related posts, and it doesn't work because at the end they+re using get_posts()
an not WP_Query
.
For example, I'm trying to manipulate the options on a WPForms field, by using their wpforms_dynamic_choice_post_type_args
filter without success because they're using get_posts()
.
Designs
No response
Describe alternatives you've considered
No response
Code of Conduct
- I agree to follow this project's Code of Conduct