Welcome to the Treehouse Community
Want to collaborate on code errors? Have bugs you need feedback on? Looking for an extra set of eyes on your latest project? Get support with fellow developers, designers, and programmers of all backgrounds and skill levels here with the Treehouse Community! While you're at it, check out some resources Treehouse students have shared here.
Looking to learn something new?
Treehouse offers a seven day free trial for new students. Get access to thousands of hours of content and join thousands of Treehouse students and alumni in the community today.
Start your free trialBoris Kamp
16,660 Pointsfilter get_posts with ACF fields, nested
I have several post types:
- Products
- Reviews
- Showcases
- Manufacturers
those are the two most important for this question
Reviews and Showcases are about a product, so when an user adds a review or showcase, they have to select the product trough an ACF relationship field
.
When a user adds a product, they have to select the Manufacturer trough an ACF post object field
I have created all my custom pages for the reviews, product and showcases, now I arrived at the Manufacturer post type. What I want here and am unable to achieve is show the latest 5 reviews, products and showcases with this manufacturer.
I know how to create a query etc, but have no idea what arguments to set in order to filter reviews and showcases (they work the same way, two levels nested) and products (one level nested) for that specific manufacturer.....
Can somebody please post me in the right direction? Here's an example of my manufacturer page on my beta website
Thanks guys!
Boris Kamp
16,660 PointsBoris Kamp
16,660 PointsHi there, is there nobody who can help me out with this?