Is there a way to get secondary link support?

Comments

VM’s picture

The developer of the theme comments about secondary menus here: http://drupal.org/node/300584#comment-985100

Jeff Burnz’s picture

Yea, spot on VM.

@teacherguy if you really want them, say for the active trail/using as a sub-menu for primary links then you can do them in a block. I have no immediate plans to change PR.

pengi’s picture

I've read the link ref'd re secondary menus; and secondary menus are not really what I'm after. I would like the option to have horizontal submenus off the primary menu. I believe this was discussed in the thread a while ago which asked for pixture reloaded enhancement suggestions. I'm posting here because of the mention of using blocks for something like this in the prev post...can you explain how that might work? I believe I've see a ref or to about that in other postings but if anyone wants to give me a clue?

What I'd like is primary links just like pr has; and when one is clicked, horizontal submenu choices would appear.

So if Primary Links had

Sports Recipes Chatter

and Sports was picked, you might see

Sports Recipes Chatter
Football Baseball Basketball

VM’s picture

AFAIK, What you describe above is what secondary menus are.

when a primary is selected the "children" of that primary (parent) are shown.

pengi’s picture

Really? I know you're skilled with drupal so I don't see how you could be wrong. But the only themes that I've noticed that support secondary menus seem to have them in some other area in the header. Submenus (what I mean is menu items that are children of primary links) in themes that support them, definitely behave as I'd like them to - only usually in vertical submenus. I'd want exactly that behavior, but displayed in a horizontal band under the primary menu.

VM’s picture

let's see if we are discussing the same thing.

images removed

Jeff Burnz’s picture

@pengi - what you are describing are indeed secondary links, which can be enabled as a block in the Header Blocks region and styled as a horizontal menu (with CSS) - this would appear directly beneath the Primary links.

If you are really down with Superfish you can modify it to display as a horizontal hover menu as well (no need for a second menu in that case), which is just a matter of initialising it with different values and a bit of CSS.

pengi’s picture

Great scott...those are more or less what I've been looking for. But like I said, the only themes that I can recall looking at that supported secondary menus had them in some area that wasn't apparently associated with the primary links.

Too, there must be some way that secodary links are associated with individual primary links...I see, one picks the primary link item as the parent?

If so then yahoo! At least as far as I can get them to work with particular themes.

pengi’s picture

OK, those are great tips...I'm 'up' with superfish, which means I know nothing about them/it. But I'll experiment.

Thanks, both of you.

pengi’s picture

Well, now I've tried it, with garland at least...which I think is regarded as ok re secondary menus? And it does not seem to work like I expected.

I created a secondary link and put it as a child of a primary link. No separate menu showed up when I clicked that primary links menu item.

In fact I don't understand what I'm seeing at all...in the blocks page, both primary and secondary are listed as disabled. If I set them to enabled in the header, they both show up way at the top. PL has all child menu items mixed in. The normal garland menu with the little triangles is there, with links just like primary should have. I am sure that's how it's supposed to work but pretty wierd. Maybe Garland is not so typical after all, in this regard?

In pixture reloaded, there is no secondary menu option, so I guess I can't experiment with that at all?

Can anyone suggest a theme that handles secondary menus like I've wanted? Just so I can see how it's supposed to be.

Sorry for writing all of this in the pixture reloaded area.

Jeff Burnz’s picture

My other theme, Newswire, handles secondary links flawlessly.

pengi’s picture

It's alike on newswire. Maybe it's flawless but I don't get what drupal is intending at all.

First both primary and secondary 'blocks' are disabled. If I enable in header, they show up as simple links in the header. So was appears to be the primary links in newswire is not in the primary links block? The links in the colored main menu band are the primary links menu items...so what's it if it's not the primary links block?

And if I go to the secondary link's menu and change it's parent to a primary link item, it's no longer presented under the primary link, it just goes away. If I look in primary links I see it's been moved there, as a child of the menu item I made it a child of.

That's exactly what I described was the case with garland. So it's apparently how drupal is set up. But I can't make any sense of it and don't find anything written about it.

Secondary links in newswire are neatly laid out under the primary links, if used the 'normal' way, but selection of a primary links item does nothing in secondary links. As stated in my original question, I want the secondary links to be related children of the primary links selection.

Jeff Burnz’s picture

@pengi

You dont need any blocks enabled for Newswire or Garland - its all coded into the page.tpl.php.

You only need to build ONE menu - the Primary menu, add items to this as per normal.

To have secondary links as related children of the primary links selection do this:

1) add them as child items under each parent Primary link, e.g.

Primary Link 1
-- child link
-- child link

and so on.

2) Then go to - admin/build/menu/settings

...and set the "Source for secondary links" as Primary Links (select Primary Links from the drop list).

Now, when you click a Primary link the child items will appear as secondary links. This works in Newswire and any theme that supports secondary links, either hard coded into the page.tpl.php (Newswire, Garland etc) or in blocks (almost all themes afaik).

pengi’s picture

OK, I'd never seen that menu settings page, very cool, very flexible. I wonder if this is documented? I swear I looked in the docs, didn't find anything like your straightforward writeup. Thank you for walking me through this.

I'm still curious about the mention you made earlier re some way of making related submenus using blocks, for themes that don't support secondary menus?

Jeff Burnz’s picture

Status: Active » Closed (fixed)

Closing, good info here but I PR will never support Secondary links out of the box.