Custom Post Type as a Taxonomy
I am stuck in a problem and I need help from you guys. Below is the scenario:
- I have two Custom Post Type: Movie and Crew
- Crew will behave as a Single Person i.e Tom Cruise, Actor(CrewType)
- CrewType : Custom Taxonomy for Crew i.e Director, Actor
The question is I want to attach Crew(Tom Cruise) to Movie(MI2) so I have the following two views:
- When goto Movie Page I have Tom Cruise listed in Cast and Crew
- When goto Actor Biography page MI2 listed in Filmography.
Thanks i advance....
I worked on a project that had a very similar scenario. You can create an additional custom taxonomy for the Crew post type called CrewMovie. The key is to have the slug for the terms in the CrewMovie taxonomy match the slug from the movie post type.
To list the crew when you are are on the movie page, you can do a custom query for post type = Crew & taxonomy = CrewMovie & term = movie-slug.
To list the movies When you are on crew page, you just list all the terms from the CrewMovie taxonomy.