Home › Forums › ACF PRO › show posts from custom post type with specific post object › Reply To: show posts from custom post type with specific post object
You are on the team single post and you are attempting to show posts in a category that are related to this post through a category. Not easy, and I cannot really do all the code for you.
CPT (team) => Categories (team selected here) => posts in categories
You need to do a reverse relationship query on the categories (taxonomy) to get a list of categories where the team is selected, very similar to this https://www.advancedcustomfields.com/resources/querying-relationship-fields/.
Then you need to do another query on for the posts that you want to show based on the categories returned in step 1.
Welcome to the Advanced Custom Fields community forum.
Browse through ideas, snippets of code, questions and answers between fellow ACF users
Helping others is a great way to earn karma, gain badges and help ACF development!
Plugin boilerplates can do some of the heavy lifting during initial development. We look at four options to speed up your plugin creation. https://t.co/ZtMsdBxAHw— Advanced Custom Fields (@wp_acf) June 5, 2023
© 2023 Advanced Custom Fields.