I'm very new to Drupal, and I have a question. I have the following terms defined in a single-hierarchy category:
Database
--General
--DB2
--Oracle
----SQL*Plus
----SQL*Loader
I've created a story that I've associated with the term "SQL*Loader". When I view the story and click on the "SQL*Loader" link, I get taken to a new page that begins as follows (note the breadcrumb trail):
Home » Database » Oracle
SQL*Loader
Getting Creative With SQL*Loader
Submitted by JonathanGennick on 1 May 2003 - 12:00pm. SQL*Loader
...
So far, so good. However, I now click on the Oracle link in the breadcrumb trail. When I do that, I get a list of articles associated with the term "Oracle", and only with the term "Oracle". What I really want is for that list to consist of all articles falling underneath "Oracle" in the hierarchy.
The problem is that the link in the breadcrumb trail specifies that child terms not be included:
?q=taxonomy/term/2
What can I do to change the breadcrumb functionality so that clicking on a crumb gives me all articles associated with not only the term associated with the crumb, but also all articles associated with terms below that parent term?
I hope my question clear. Let me know if it's not. My site is gennick.com, in case anyone wants to take a look at what I'm doing.
My main concern here is that if someone clicks a breadcrumb for, say, "Oracle", then I want that person to have visibility somehow to all articles associated with "Oracle", and to all other subtopics underneath "Oracle". It wouldn't bother me if the user just saw a list of "Oracle" articles along with a list of subtopics. Surely there must be a way to make that happen.
Comments
Taxonomy and breadcrumbs give me headaches
I would like to convert to the category module so breadcrumbs can behave themselves. There is also a taxonomy_breadcrumb module which can help you customize breadcrumb behavior. It seems like core taxonomy behavior with breadcrumbs is difficult to tame. I'm not saying it isn't possible, but it might be easier to rely on the above mentioned modules. Check them out and see if they help.
breadcrumbs not logical?
I must say, I'm a little surprised at the default breadcrumb behavior. It doesn't seem logical to me. OTOH, the Drupal developers have probably thought things through, so I can't help but wonder whether I'm the one missing something.
As it stands now though, if you go to gennick.com, say to the following page:
http://gennick.com/?q=taxonomy/term/6
...and you click the breadcrumb for "Database", you'll be taken to a "blank" page. That "blank" page will state that there are "currently no posts in this category." But that's not true! There are plenty of posts in the "Database" category. They are simply linked to subcategories. But how are readers to know that when Drupal gives no indication of subcategories, nor any way to drill down into them?
Taxonomy list not showing subcategory items
Hey there,
I had the same hangup. You have to enable multiple category slection in the vocabulary setup. Then when creating a node for a sub-category of say databases you must select BOTH the subcategory and the database super category. Then it will show up under both. This is the only way I was able to do it.
hope this helps.
--------------------------------------
Vince Tingey
IT Systems Coordinator
Michael Smith Laboratories
University of British Columbia
Vince, thanks. I've
Vince, thanks. I've reluctantly come to the same conclusion as you. And since I must multi-tag my posts, there's little to no benefit at that point, that I can see, from a hierarchy. I've gone to a flat model that is just a list of terms.
Taxonomy and bread crumbs – solution
If I would like to view post of subterms of e.g.
?q=taxonomy/term/2
I can use
?q=taxonomy/term/2/2
where secon number is depth.
So I decided to rewrite the code for breadcumbs in my theme:
I don't know if this is really right way how to do it. My be better will be to hook on some function which generate the links for breadcumbs. But I don't if there is such hook.
Slight improvement
Instead of
'term/\2/100'is better
'term/\2/all'for all sublevels
nice trick
I noticed it removed the list of subcategories on the term page. Is it on purpose?
Also, how to use it for any term (without having to input it manually)?
* What I desired was a list
* What I desired was a list with only top term in headline. Personaly I do not like the style which is produced by, e.g.,
taxonomy/term/1+2. It does not fit idea of my web. But I see that it could be useful somewhere else.* I don't understand what are you asking preciselly. However the solution is above where I wrote a theme function.
Taxonomy Context does it
The module lists all child terms and nodes below a given parent term, among other functionalities.
Durval Tabach
Durval Tabach