Hello,

I've created a Vocabulary titled "Music" and have created 3 terms "Seventies"..."Eighties"..."Nineties".

I think I have figured out how it all works, but for some reason I've missed how to get the actual menu list to appear in the (main menu) block.

I'd like the vocabulary "Music" to appear in my main menu, and when clicked, a drop down list:

> Seventies
> Eighties
> Nineties

to appear below it. When say "Seventies" is clicked, for another list to drop down with the content (blog posts) I have made within the "Seventies" term to appear below that.

so...

*Music
> Seventies
> Article 1
> Article 2
> Article 3

I apologise if this has been asked before but for some reason the search facility on this site doesnt like me too much ;)

Would appreciate some help with this!

Thanks.

Comments

Thn’s picture

Menus and Taxonomy are two separate things. It sounds like you might be equating them.

To see everything under a given term will be a url like mysite.com/taxonomy/term/12 (if you have clean-urls enabled) ... you can get the number of the taxonomy term on the page where you edit categories (when you edit, the number will be in url)...

So you can then go to your admin/menu ... and create menu items that link to those urls - in the way you described.

As far as including blog posts in the menu - I don't think that's possible, the menu doesn't update dynamically. Maybe Taxonomy Block can do something like that for you...

SludgeMeister’s picture

Thanks for the reply Thn,

Not sure if I understood correctly..

So it isn't possible to call up my entire Taxonomy structure in a menu form, automatically? I thought it would autopublish the structure for me, and have the hierarchy in place.

Like this site, when someone clicks "Create Content" (under the user menu) it drops down:

> create content
* book page
* forum topic
* project
* issue

That is what I want to be able to do with my entire Taxonomy.

cept' replacing "create content" with the Vocabulary name, and have my Terms for each link below it?

venkat-rk’s picture

Here is the best tutorial you can find on building menus based on taxonomy structure:
http://nicklewis.smartcampaigns.com/a-taxonomy-menu-that-goes-to-11

It uses the taxonomy_menu module. Just one downside to using this module. It doesn't implement pathauto, so you will get urls such as taxonomy_menu/1/23/10 etc. If you can live with that, this is a great way to build your menus.

Update:

If you want your content to appear below the menu items, your best bet is the taxonomy_context module. Once you install and enable it, you will see blocks saying, 'Context for...' at administer>>blocks. Just enable them and you will get nav menus based on taxonomy. And then, to get your posts below the taxonomy terms, just play around with its settings at administer>>settings>>taxonomy_context.

I suspect you will quickly find you don't want the posts to appear below the taxonomy term in the menu.

SludgeMeister’s picture

Thanks alot ramdak, taxonomy_menu was *exactly* what I was looking for!

*cheers*

Thanks again.

venkat-rk’s picture

You're welcome:-)

SludgeMeister’s picture

The module is displaying the Vocabulary and then the Term below it, when selecting the term its displaying all the content of the term on one page.

Is there anyway to get another drop down when the term is selected to display each content page as a link.

At the moment:

* Music
> Genre 1
> Genre 2
> Genre 3

When I select a Genre it shows a page with every content item listed.

I would like if possible to get:

*Music
> Genre 1
- Article 1
- Article 2
- Article 3

> Genre 2
> Genre 3

Half way there with this anyway. The "Article" are Blog posts currently, but I dont mind if I have to convert them to Stories or Pages to be able to have this option.

Thanks again.

Tom

EDIT: Woops, sorry...I missed the taxonomy_context part. Can this module be used with the taxonomy_module to acheive what I am asking?

venkat-rk’s picture

I would like if possible to get:

*Music
> Genre 1
- Article 1
- Article 2
- Article 3
> Genre 2
> Genre 3

It is a while since I used taxonomy_context for this purpose, but I think it will do what you want. Just enable sub-term info in its settings.

I think you can also limit the length of the teaser that shows in the menu.

SludgeMeister’s picture

For some reason, its not doing anything at all.

I have it installed, all options configured on it and its made 0 difference.

If I disable Taxonomy_Menu and try it, the Vocabularies are totally removed from the menu.

I have both switch on and it doesnt make a blind bit of difference.

No change still just:

*Music
> Genre 1
> Genre 2
> Genre 3

Its part way there, just want to have my content items (pages, stories, blog topics etc.) listed under each genre.

Argh, confusing!

Nick Lewis’s picture

This actually doesn't look like a case where taxonomy_menu will solve your problem. Taxonomy_menu gets you 2/3's of the way there, but it doesn't display the titles of articles under the terms. That said, I don't think there are any modules that will give you exactly what your looking for. One option would be to use menu_otf (menu on the fly) and simply file all of your content under menus, but that has lots of long term disadvantages.

Here's what I would recommend:

**Use taxonomy_menu for your primary navigation**

The great thing about taxonomy_menu is that it gives your visitors a way to drill down through your content. If you used the menu_otf function, and manually filed your articles, you'd deprive your visitors of that. So lets say that your vocabs are

+Jazz
+Classical
+Hip Hop

If you click classical, you'll get a view of all articles that have terms from the classical vocab, and the menu will expand into your subterms.

+jazz
+Classical
---baroque
---classical
---romantic
---impressionist
---polytonalism
---modernism
+hip hop

Obviously, there is an advantage to not displaying the titles of the articles at this point. A good rule of thumb is that the more navigation items you have, the less useful your navigation system is.

**Use taxonomy_block to list recent articles for parent, and child terms**

Let's say you click "polytonalism" in the above navigation menu. Assuming that there are no child terms to polytonalism, the menu item will merely highlight itself so that user knows where they are. But, there is no list of articles filed under polytonalism available. Instead of torturing yourself by trying to extend taxonomy_menu to show those articles, I'd use taxonomy block to display recent articles. Thus, in one block you'd have the navigation above, and in another block which only appears when you're on a specific term, a list of 5-10 of the most recent articles would appear.

So far as I can see, this compromise has no negative impact on how easily navigatable your site is. Actually, I think this system would be better from the user perspective. Hope this might help point you in the right direction.

--
"I'm not concerned about all hell breaking loose, but that a PART of hell will break loose... it'll be much harder to detect." - George Carlin
--
http://nicklewis.smartcampaigns.com

--
"I'm not concerned about all hell breaking loose, but that a PART of hell will break loose... it'll be much harder to detect." - George Carlin
--
Personal: http://www.nicklewis.org
Work: http://www.zivtech.com

netlynx’s picture

posted in error