1

My current WordPress site only exists of pages. The structure is as simple as this:

example.com/hotels 
example.com/attractions 
example.com/restaurants 

I want to use Custom Post Types to add listings about individual hotels, attractions and restaurants. The new structure will look like this:

example.com/hotels/myhotel 
example.com/attractions/myattraction 
example.com/restaurants/myrestaurant

With myhotel/myattraction/myrestaurant being a Custom Post Type.

All listings share the exact same custom fields.

My Question: Do I need to create 3 Custom Post Types (hotel/attraction/restaurant) or should I register just 1 "global" custom post type - eg called "Place" - and specify if its a hotel/attraction/restaurant using hierarchical Custom Taxonomies?

What are the advantages/disadvantages of these different approaches?

Thanks!

1 Answer 1

3

Personally I would structure it like a CPT for each Hotels, Attractions, Restaurants. Then a custom taxonomy that ties them together for instance "Places" with children like "Locations", etc.

If the site has a lot of connected data it is a really good idea to sketch out the relationships on paper or using software like Visio so you can visually see how it all fits.

2
  • Why would you prefer create a CPT for each item? Maybe for flexibility in the long run? Or is there another reason? Viseo is a good idea, I´ve been using Excel but it´s not very visual.
    – Mattvic
    Oct 12, 2011 at 18:30
  • 1
    The reason I would thing the top levels items as CPT's is it's very likely the display data is very different , for instance a Restaurant page would not have the same stuff as a Hotel page.
    – Wyck
    Oct 13, 2011 at 1:40

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge that you have read and understand our privacy policy and code of conduct.

Not the answer you're looking for? Browse other questions tagged or ask your own question.