3

I have contents that can be tagged per taxonomy terms (with hierarchies in content type), say,
Events > weddings
Events > birthdays
Events > public > national day celebration

The events (which is a vocab) actually turns into a menu (using taxonomy menus) and I want it so that when users click 'Events' menu all contents tagged weddings, tagged birthdays, tagged national day celebrations will show up on the page.

This content type (Events) has a field called 'Type' which is a hierarchical taxonomy list from the vocab 'events'. I had it set so that the term lineage will be save in the hierarchical select settings, I was under the impression that for any content tagged 'weddings' for example, this same content will also be tagged as 'events' by the system due to 'save term lineage' settings...

When I go to http://mysite/events (which i already configured using pathauto, and used views to display taxonomy terms related to nodes) none show up, as if none is being tagged 'events' at all. But when going http://mysite/weddings i get all contents tagged under weddings only (which is right).

Thanks!

EDIT: This content type (Events) has field called 'Type' which is NOT a hierarchical taxonomy list but a select list. Sorry for that.

  • Your question is very similar in nature to mine: http://drupal.stackexchange.com/questions/19236/how-do-i-distinguish-menu-items-without-children-and-display-different-content-i – Ashlar Jan 9 '12 at 17:00
  • and we were an hour apart! :D – jan Jan 10 '12 at 15:40
1

Try Hierarchical Select module.

Hierarchical Select has the ability to save the entire lineage of a selection or only the "deepest" selection. You can configure it to force the user to make a selection as deep as possible in the tree, or allow the user to select an item anywhere in the tree. Levels can be labeled, you can configure limit the number of items that can be selected, configure a title for the dropbox, choose a site-wide animation delay, and so on. You can even create new items and levels through Hierarchical Select!

1

I believe you may need to have the content tagged in both terms, "Events" and "Type" for this to work without custom coding.

You can get this through a view or custom module quite easily, though. If no answers posted later on, I will post you an update when I get home as I am writing this from mobile.

Good-luck

  • how can i include the ancestors of this term so that it will have two terms tagged? or three terms tagged? (depending on how many levels the vocab has)... without resorting to too much hacking... – jan Jan 10 '12 at 15:23
  • 1
    I think this would be pulled off in a custom module, you could add a custom submit function that adds the terms to parent terms. – stefgosselin Jan 10 '12 at 19:17
  • That kind of works...though I was hoping the relationship would be automagically determined and rendered... – Alex.Barylski Jul 16 '14 at 17:08

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.