5

I just read Should I use a seperate content type?, and it's got me thinking.

Say I had a site with twenty-five content types, with some of the content types sharing enough of the features of some of the other content types to make some kind of "inheritance" worthwhile: I'm thinking in terms of object-oriented PHP here. Is content type inheritance possible in Drupal 6? Is it possible in Drupal 7? Or 8? Could a module be written to make it possible?

6

For Drupal 7 there's the Bundle Inherit module.

2

You might consider using References module which is exactly what it sounds like, the ability for one node to reference another node for which you can easily retrieve the information of the referenced node/user/etc. through Views or the PHP API. This is very similar to using taxonomies except they are treated as a node would generally be treated.

You can set up automatic back references with a module or simply do a back reference through views computationally upon request.

edit: This references system is less like inheritance and more like composition which is generally the preferred method in object orientation computer science theory.

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

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