I have some questions reguarding Taxonomy & Site Navigation.
Project Overview:
I am creating a knowledge base site for a college. At first we were going to make a book in Drupal to contain all the content on the site, but limitations of the book modules lead us to thinking of using taxonomy to classify pages in Drupal.
Categorizing our Content:
I started to create a structure for our content.
Vocabulary: College
The Vocabulary options we want are hierarchy for all content types, allow related terms, and allow to select multiple terms.
Top-Level Terms: Students, Faculty, Staff
This leads me to my first question/problem:
I wanted to add a new term, computers, but I wanted this term to be a child to all top-level terms. So I selected Students, Faculty, and Staff as the Parents for my new term Computers. When looking at the category overview page I see the term Computers under Students, Faculty, and Staff like I wanted; but when I preview form on my Vocabulary I get the following:
College:
Faculty
-Computers
Staff
Students
To me I figured if someone was adding content for something about computers for students then they should be able to select Students -> Computers. But that isn't the case as the form doesn't allow for that option.
My second questions/problem:
I want the users to be able to navigate through the site using the categories. For example if the user was a student and wanted to know when the computer labs opened they would navigate to Top-Level Term Students then a list of child-terms to Students would appear, they would then click computers, and a page would return links to all the pages that were tagged computers, there they would find a page titled "computer labs" and would find the answer to their question. In testing this when I click "Students" (which I put a link to in my primary links) nothing is returned because nothing was tagged "students". But I figured that any child terms would be returned in this case.
After explaining what I am trying to do can anyone lead me in the right direction?
Thanks,
Eric
Comments
Taxonomy
Eric, as I think you realise, you're nearly on the right track but not quite. You need two vocabularies, not one. Set up the first 'College' containing only your top level terms. Then set up another called 'topic' or something that contains your second level terms such as 'computing'. Then, when you create a node about computing you assign it to the topic 'computing' and whichever of the 'college' terms are appropriate.
Having done this you can then choose to see all nodes relating to (say) 'students', or all nodes relating to 'computers', or all nodes relating to 'students' and 'computers'.
In this way you only need one taxonomy term for computers, and you don't have to assign every node about computers to every College term.
There are lots of modues that display taxonomies in different ways so have a play with them until you find something that does what you need.
Hope this helps
Jez
I get what your saying
I get what your saying but...
I still don't see how this will work like I wanted. I am looking for something similar to Slashdot.org's site.
You can click a main category and it will return a list of sub-categories to the parent and below that a list of all content that belongs to everything under the parent. How do I achieve something exactly like Slashdot.org?
In my case the user would select a main category which would be their user type (Student, Faculty, or Staff) From there they would then see a list of sub-categories (main content topics) that would futher refine the list of returned content. Then from there if need-be I could have sub-sub-categories (sub content topics) to refine the returned results even greater.
So if I create 1 vocabulary: Users; it would contain Terms: Students, Faculty, Staff.
Then I would create another vocabulary: Topics; it would container Terms: Computers, Policies, Technologies. Also say I wanted to add another Term: Wireless that would have multiple parents: Computers & Technology.
From here I add a Page: Campus Wireless Policy that would be tagged Students+Faculty+Staff for Vocab: Users, and Wireless+Policies for vocab: Topics.
Now say a student is wondering if they can access the WLAN on campus they would go to my site and do the following:
Click "Students" which is their user type. It would return the list of topics, then could then select Technology or Polices, then they are returned the sub-topic Wireless. They click that link and then they see the content Page "Campus Wireless Policy" and find their answer. <--- this is what I am after with my drupal site.
Eric
Associations
What you're asking for is, when you think about it logically, pretty much impossible. As far as I understand it, you want the following setup:
It's just not possible to have a category system that supports multiple parents for a single term, and that supports hierarchical browsing. A hierarchy is a tree. A tree is a mathematical structure where each node has (at most) one parent. If you allow your terms to have multiple parents, then your category system is no longer a tree.
This is fine as far as Drupal's concerned - the taxonomy system is very flexible, it fully supports a non-tree-like web of categories. But if you sacrifice the tree structure, then don't expect to be able to have hierarchical (i.e. tree-like) browsing on your site.
Think about it like this: say someone goes to this page on your site:
mysite.com/taxonomy/term/42
Where term 42 is "Life, the Universe, and Everything", and it's a child of term 31 ("Marvin") and term 26 ("Trillian"). What will the user's position be in your site's hierarchy? Will it be:
home -> marvin -> life, the universe, and everythingor will it be:
home -> trillian -> life, the universe, and everything??
Of course, since taxonomy supports multiple parents, it won't even try and work out any hierarchy, it will just give you:
home -> life, the universe, and everythingMy advice would be to consider disabling support for multiple parents. And now for what you were actually asking about...
If you want to display a list of child terms on a taxonomy term's page, then I suggest that you try the taxonomy associations module. It lets you display a node on a taxonomy term's page, as that term's description. It also includes a special filter for inserting a list of child terms into that associated node. This module will work with Drupal 4.5 or 4.6.
If you're going to have a vocabulary for each 'level' of categories, and you want the categories in one level to be the children of categories in another level, then you might also want to check out the distant parent module.
Your scenario is (apart from the whole multiple-parents thing) exactly the kind of scenario that I'm hoping will be much easier to implement, once work is started on the proposed category module. By merging the book and taxonomy modules, things like a generated list of child terms will be done automatically, and will be a much better solution than what's currently available only with taxonomy_assoc.
Jeremy Epstein - GreenAsh
Jeremy Epstein - GreenAsh
Thanks more making things clear...
Jeremy,
After reading your post things have become more clear for me. Also thanks for posting the links to modules I can use, and what they can do for me situation. The multiple parents is something I can disable as the ability to add content to 1 or terms will be a useful feature. This way we won't have redundant content as content that applies to multiple users (my top-level categories) can be tagged multiple terms.
Also merging the book and taxonomy modules is exactly what I am trying to accomplish. My site is basically a handbook for the Informations Services department of the college I work for, but the limitiations of the book seem like they could be overcome with the felxibility of taxonomy, making a merger a great solution.
Also: My Drupal install in using Drupal 4.6.1. I have noticed your Taxonomy Associations module is for 4.5. Will this module still work for me? or should i wait for the categories module? ;)
Thanks again,
Eric