Hi guys!
Trying to figure out how to make for Omega Theme a two-level menu which looks similar to ; http://www.telegraph.co.uk/news/, I finaly decided to use a great module Superfish.
With this module I created block with Main menu designed in navbar style. But the problem is that I cannot fix the second level menu always opened.
Does anybody know how to do it?
I use Drupal 7.12 and Omega 7.x-3.1.
Mentioned menu is Main menu. All parented items marked as Show extended
In Superfish block I used following options:
Menu Depth - 2
Menu Type - NavBar
Path class - sf-menu sf-navbar ( as mentioned in http://users.tpg.com.au/j_birch/plugins/superfish/#sample4)
Path levels - 2
Regards Oleg
Comments
Comment #1
marcoka commentedThis has nothing to do with omega. Your question is about superfish functionality.
Comment #2
mehrpadin commentedPrivet,
Just change the Path class back to active-trail :)
Comment #3
oo_nn commentedPrivet!
I have changed Path class back to active-trail, but it did not help. Second level menu is still collapsing, when I do not point on yhe first level item :(
Comment #5
mehrpadin commentedAre you sure you're using the v1.9-beta4?
Comment #6
oo_nn commentedYes, I'm sure. To be shure I even reinstall beta 4.
I tried V1.8 and v1.9-beta4. I found that they are slightly different in CSS. But both of them gave me the same result: second level of menu collapses despite Path class is active-trail or any other.
You can check it by youself at new-m3m.ru at 178.79.145.82.
Comment #7
tegia commentedHi,
I have exactly the same problem with this version (although I don't use Omega but another third-party theme) ...
If someone have a solution, I am very interested !
Versions:
Thierry
Comment #8
tegia commentedHi again,
My mistake !
I installed a (close but) wrong version of Superfish library in "sites\all\libraries" !!!
The correct version is "superfish-library-for-drupal-v1.2-beta.zip" :-)
It's working fine now ...
Regards
Thierry
Comment #9
tegia commentedActually, the problem occurs randomly :-(
(user cache is activated in drupal)
==> Hmm, NO ... It's solved. Executing "Clear all cache" was just needed :-)
Comment #10
oo_nn commentedHi Thierry!
Would you please explain were did you find "superfish-library-for-drupal-v1.2-beta.zip"? On https://github.com/mehrpadin/Superfish-for-Drupal I found only "mehrpadin-Superfish-for-Drupal-1.0-4-g1571b1d.zip" :(
Thank you
Oleg
Comment #11
Dew commentedI could ask for writing what and which file must I modify so that the menu is always open in?
Comment #12
mehrpadin commentedОлег, that's the same thing, just weird package naming by GitHub (library packages used to be on Dropbox). Also, I can't access your website.
Tomasz, original issue answered.
Comment #13
tegia commentedHello Oleg,
Sorry for late, I was busy on other critical subjects ...
Please try this (non official) link: http://dl.dropbox.com/u/22795799/superfish-library-for-drupal-v1.2-beta.zip
Best regards,
Thierry
Comment #14
broonHey there,
I am experiencing the same issue. I am using
I created a menu with two depths. The superfish block is configured to work with two levels and to have both levels open at all times. Path class is "active-trail". However, upon page load the second row is not being displayed. I have to hover the first-level menu item to have it show up. Also, there's no "active-trail" class set anywhere.
Anything I am missing?
UPDATE (20120503): Second level is now showing up. Still, active-trail class is still missing from parents.
Comment #15
oo_nn commentedI also noticed that something was wrong with active-trail
Comment #16
oo_nn commentedHi, Paul!
How did you make it work?
Oleg.
Comment #17
broonActually, I am not really sure of what finally caused it to work. But I ran update.php in between and cleared the cache several times. I strongly assume it has been a cache issue.
Comment #18
oo_nn commentedUpdated everything, cleared the cache a dozen times. Still does not work. :(
Comment #19
loparr commentedI am facing the same issue, using ver. 7x1.8 I can not find 1.9 anywhere :/
Did someone managed to show both levels at the same time?
edit: OK , I found the 1.9 version, was not inside download box though.
I am using the mehrpadin-superfish 1.0.4 version of library
I found a checkbox in block settings - take expanded option into effect - but no change.
any ideas?
my site is test.vypadavanie.net
thank you
Comment #20
broon@loparr: For module version 1.9 you should use superfish library version 1.2!
I was playing around with superfish and tried to debug some variables. I found the following pattern. For my site I have special content type which is used for all main menu items. Thus, all primary (1st level) items link to a node. If a menu item from second level links to a view, superfish works as expected, upon page load the submenu (2nd level) is already opened and some css classes are present (`sf-breadcrumb`for the parent and `active` for the current menu item).
However, if the submenu item links to a node, nothing works. In superfish.module function `superfish_build_page_trail()` I debugged the `trail` variable and while its content is correct for a view, the variable stays empty if the link target is a node.
Also, if clicking on a primary item (1st level) superfish doesn't work either (since it's a node). If I add a view to the 1st level, superfish works for that menu item.
Comment #21
broonI finally found a solution to fix the nasty Drupal core bug regarding the active-trail. Thanks to http://www.designhammer.com/blog/active-trails-menu-items-drupal-7 and the two lines of code mentioned there, every single menu is working as expected now.
I tried Drupal core menu, Menu block as well as Superfish, they are now all getting the appropiate "active" and "active-trail" classes.
Comment #22
SNaKeMe commentedHi Paul B.,
i have the same bug with the nodes in the menu. how do you edit the "trail" variable? can u post your code here?
have corolla theme installed.
Comment #23
maxview commentedI used latest version of all needed scripts, but still got one problem, the sub menus under "home" menu wouldn't keep open when the "home" is selected.
Comment #24
broonHey SNaKeMe,
sorry for replying so late, I totally missed your request.
Actually, all I did was to use devel's "Execute PHP" functionality and run the two lines mentioned in the article:
Of course, you need to alter the first line to resemble your menu machine names.
Paul
Comment #25
jchin1968 commentedHi assenal.
Did you get #23 resolved? I'm having the same problem where if I'm on the home page the sub-menus for home don't stay open unless the mouse is hovering over it. But, if I'm on a different page, the sub-menus are working correctly and do stay open. Thanks.
Joe.
Comment #26
maxview commentedHi jchin1968,
It's done: http://www.marketingthread.com
Don't use the default home page setting, use other url containing no "front". < and > are filtered here, you know what I want to tell.
Comment #27
theohawse commentedGuys, open a new issue if your still having difficulties cheers!