When to use containers versus categories has me scratching my head (in the category module).
For example, in a site about plants, I need to categorise something like Family -> Genus -> Species - > Plant. Being more used to relational databases, in a db I would create 4 tables, each with a relationship to the next.
A Plant record is unique based on 4 fields: Genus, Species, Botanical Variety, and Cultivar. The last two fields are optional.
I'm not sure if I should create a container "Families" and add each (of thousands!) of families as categories within that container. Or, should each individual family also be a container for genea, rather than a category? It seems it could be done several ways, eg:
- family01 (category)
- genus01 (category)
- species01 (category)
- plant01 (story)
- plant02 (story)
- plant03 (story)
- species02 (category)
- plant04 (story)
- plant05 (story)
- species01 (category)
- genus01 (category)
---== OR ==---
Each of the categories in the above example could be specified as containers. Just can't work out which way I should structure this, despite reading so many posts my head is spinning!
Can anyone please suggest which way I should go, and why? MTIA!
Comments
Hi Max, I think you would
Hi Max,
I think you would need to make a container for "Plants" wich will have categories families, sub-genus en sub-species. I'm not to sure about Cultivar, but that's merely because of my lack of plant knowledge.
The category module doesn't store your categories in 4 different tables but only uses one for structure (as far as I understand it).
This looks like:
Node Parent
2 1
3 2
4 3
5 3
6 3
7 3
1
-2
--3
---4
---5
---6
---7
This way the catergory module is able to make "unlimited" depth structures without editing one table.
Dinilu.eu & Dinilu.nl & Dinilu.de & www.tit.nl
Hi Mark I'm sure you're
Hi Mark
I'm sure you're right about the category module - I believe it uses just the one table 'category_hierachy' to maintain structure. The 4 tables I spoke of would typically be used in a relational database - not the case with Drupal & MySQL.
I follow your structure example, although I'm still baffled by the concept of a container, and when it should be used....
Max Hugen
Australia
I believe you can see the
I believe you can see the container as follows:
If each of your categories is a file folder, the container is the drawer that holds all your file fodlers (categories).
I hope that makes sense.
Cheers,
Balarama Bosch
Cheers,
Bala Bosch
but how does one display
but how does one display every story in a category on a "page" or have it show up in the navigation bar (menu module)?