I'm trying to get my taxonomy which is multilevel like this

trees
--apple
--peach
--pear
flowers
--rose

etc
to show like this with a Parent Item and the child terms with it.

Trees Flowers
apple , peach ,pear Rose

I just can seem to get it to show individual taxonomy terms or them all and not group them under a parent term. I seem to be overlooking something very basic here.

Vmpwraith

Comments

zahor’s picture

What you do (if I understand your question) is under fields, choose "Taxonomy: All terms", then check "limit terms by vocabulary" and choose a single Vocabulary, then add that Vocabulary name as the label. If you want to show several Vocabs, just add another instance of the "Taxonomy: All terms" field and repeat above (you can have as many as the same field as you like).

JasonMoreland’s picture

The only problem is that it shows the entire

trees | apple
trees | pear

etc I was hoping to just be have to group them under headings maybe I need to look at taxonomy weights again.

trees (label or hidden field for grouping)

apples | pears (terms for navigation)

zahor’s picture

To prevent that, you click on the Gears icon under Row Style, and you choose "Group By" and select field name that should be grouped. So instead of
Trees | apple
Trees | Pear

You'll get

Trees
Apple
Pear

The only drawback here is that you can only group by a single field, so if you have multiple taxonomy fields you won't be able to group by those.

If I were doing this myself, I'd probably write a a small module that adds 1 block to handle this for me.

JasonMoreland’s picture

Oh well at least that works. I'm not to hot on module creation yet so maybe I'll just have to use multiple views and panels. Looks like I'll have to break the taxonomy down a little from one giant list into smaller bites.

thank you Zahor

zahor’s picture

I almost forgot, see if the Taxonomy Menu can help, since technically, it just gives you a list of terms - which is essentially what you want to do.

JasonMoreland’s picture

I'm using it which is great. The only drawback is you cant assign one taxonomy to several menus and I already have the taxonomy working as a dynamic menu. So I'll have to clone the taxonomy then set it up as a different menu. Maybe I'll play with the custom paths for taxonomy menu. The issue with separating the taxonomy is that the second and third taxonomies etc are not associated with content.

I'll just have to keep plugging away at it :-)

Cool_Goose’s picture

Add a relationship of Parent Term
Add TWO Taxonomy terms, one of which will use the relationship and not display anything.
Use grid (or whatever you like) and group by the term that uses that relationship.

Ta da :P (just used the same thing myself :D)

julianmancera’s picture

Hi Cool_Goose,

That's what I needed, here is a cleared explanation. For those out there trying to do this you need to create a taxonomy view not a node view and follow the instructions here :

http://www.phpjavascript.com/drupal-views-taxonomy-parent-term-and-child...

PD: The parent relation should be required so you don´t have duplicate terms