Trying to figure this out, using ACF Pro…
I’ve created two custom CPTs. CPT one should act as a container for multiple variations of CPT two. Variations of CPT two are indicated via several custom taxonomies that can be selected while I’m preparing a post for publication. Just like traditional categories or tags.
What I’m trying to determine is if the right approach is to have these two CPT behave like Pages instead of Posts to access the parent-child function? Or is there a way to set up a parent child relationship between these two CPTs as they are?
I’ve been hunting for a few hours and can’t find the best way to set this up.
[ad_2]
Sounds like you need a CPT and custom taxonomies (categories) to organize the content.
Using page instead of post will allow you to nest pages under pages of the same post type.
When you create the CPT in ACF, you just need to check the “Hierarchical” box on the first page if you want to have parent/child situation.
As the other user mentioned though, sounds like what you’re trying to do is backwards. You can’t have parent/child relationships between multiple post types. You either create Taxonomies to categorize the items in your custom Post Type, or you just use the Parent/Child ability in that custom Post Type. But you can’t do it across separate ones.
Another option depending on what exactly you’re trying to do, would be to keep the separate CPT but then look into setting up Bi-directional relationships between them. [https://www.advancedcustomfields.com/resources/bidirectional-relationships/](https://www.advancedcustomfields.com/resources/bidirectional-relationships/)