Howdy,

I have a really nice taxonomy set up, where I have News then several sub categories of news. This is repeated with other terms, like Media for instance.

I would like to make it so that my content contributors are forced to select a sub-category from the terms list. Is this sort of thing possible?

Many thanks,

rob

Comments

gollyg’s picture

any taxonomy can be set to 'required' - meaning that node types assigned to that taxonomy cannot be submitted without a value. For the system you are talking about there are (at least) two possible ways of approaching it

  • one large taxonomy with each subcategory
  • two taxonomies - one with the major categories, the other with the subcategories. This will be good if you have the same subcategories for each major category as it will make it easy to select things on the basis of either category, subcategory, or both.

In this case each taxonomy would be set to required.

jetsetter’s picture

Hmm. I feel like I'm already committed to this structure where i have "Topic" as the taxonomy and News as one of the top level categories. Does your explanation mean that I can set the sub-level categories as required while users can _not_ choose the top level categories?

gollyg’s picture

At the moment users must need to make a selection of both the topic and the top level category? If you want to control the types of stories that individual users can create how about using CCK content types for news, media, etc. This will give you role based control over who can create what. Taxonomies can be restricted via content type, so you could have different sub-categories for each content type. This would give you maximum control for minimum effort. But you would have to scrap your current taxo :-(

nathan573’s picture

I have the exact same issue as you. I have a medium sized, hierarchical taxonomy of which I only want people to be able to select the "heaviest" subcategories. In your posting "Force Use of Sub-Category Vs. Top-Level OR Disallow/Disable Use of Certain Categories" you seem to have the same problem.

I know that the "Category" module introduces "Containers" that would do what we want - basically make a taxonomy term unusable to nodes as a term, yet allow it to have normal taxonomy associations with other terms. This module is not stable though and this is not an option for my present project.

gollyg’s picture

I have used the category module on a few sites, and I think that you are right when you say it is not stable. It has a great amount of potential, and a lot of thought has gone into it, but unfortunately it has broken pretty badly in the menu area.