Support for Drupal 7 is ending on 5 January 2025—it’s time to migrate to Drupal 10! Learn about the many benefits of Drupal 10 and find migration tools in our resource center.
Hello,
I am playing around with this theme as it is so clear and simple, but classy looking. Thanks for providing it.
I just noticed that the main menu does not offer a second level and tried to expand the CSS file accordingly, but somehow the second level doesn't show up.
Is there another part of the code where I have to implement a second level?
Thanks for helping me out on this one.
Kirsten
Comments
Comment #1
KirstenLangholz CreditAttribution: KirstenLangholz commentedReplaced Main Menu with HEADER area and included SuperFish menu.
Comment #2
PvO CreditAttribution: PvO commentedHi Kristen,
Could you please describe for me how you did it? I would like to do the same but do not know the exact steps.
Thanks,
Piet
Comment #3
mohammed76hi.
I tried to assign the super fish menu to the header area, but it didn't work. the theme doesn't print header at all in the latest stable d7 version.
I even tried doing something like:
<?php print ($header); ?>
, but that didn't work.could anybody please help with this?
Mohammed.
Comment #4
teguh.syahputra CreditAttribution: teguh.syahputra commentedI tried to use nicemenu from http://drupal.org/project/nice_menus and have successfully to use dropdown menu, but could not put the menu on the main menu of the old block. :)
I put block into Header Top Right.
How to put on main menu block ?
Comment #5
donbuche CreditAttribution: donbuche commentedHi,
I also tried to use the module 'Nice Menu'. After this, I applied the CSS command "display:none" to the #navigation codeline of the theme's css file.
After this, with CSS and the command "position:absolute" I moved the block to the navigation region and customized the block like the original navigation bar. It's a simple way to have second levels of submenus in this theme.
PD: Sorry for my bad english...
Joan Galtés.
Comment #6
mohammed76@donbuche could you please describe in more details how you did it? specifically how you moved the block to the navigation bar?
Comment #7
tumbledown100 CreditAttribution: tumbledown100 commentedI changed some code to produce a good dropdown menu.
in page.tpl.php on line 53, change
print theme('links__system_main_menu', array('links' => $main_menu, 'attributes' => array('id' => 'main-menu', 'class' => array('links', 'clearfix'))));
to
Then in style.css on line 348 change:
#navigation ul#main-menu li a {
font-size: 1.2em;
color: #6D7E8F;
}
#navigation ul#main-menu li a.active,
#navigation ul#main-menu li a.active-trail,
#navigation ul#main-menu li a:hover,
#navigation ul#main-menu li a:focus {
color: #0B72B7;
}
to
/* 1st level */
#navigation ul.menu {
display:block;
padding:0;
margin:0;
}
#navigation ul.menu li { display: inline-block; vertical-align: middle; padding:0 5px 0 0; margin:0; }
#navigation ul.menu li.last { padding:0; }
#navigation ul.menu li a {
outline:none;
padding: 5px 10px;
text-decoration: none;
display:block;
color: #6D7E8F;
font-size: 1.2em;
text-align:center;
}
#navigation ul.menu li a:hover, #navigation ul.menu li a.active, #navigation ul.menu li a.active-trail {
text-decoration:none;
color:#cccccc;
border-radius: 5px;
-moz-border-radius: 5px;
background-color: #1E517E;
}
#navigation ul.menu li a:after { content: none; }
#navigation ul.menu li.expanded { position: relative; }
#navigation ul.menu li.expanded:hover a {
border-radius:5px 5px 0 0;
-moz-border-radius:5px 5px 0 0;
background: #1E517E;
color: #CCCCCC;
}
/* 2nd level */
#navigation ul.menu li.expanded ul.menu {
width: 190px;
z-index:100;
font-size:12px;
padding:0;
background: #1E517E;
display: none;
position: absolute;
color: #FFFFFF;
}
#navigation ul.menu li.expanded:hover > ul.menu { display: block; }
#navigation ul.menu li.expanded ul.menu li a { font-size: 15px; color:#cccccc; padding:10px; display:block; width:180px; text-align:left; border-radius:0; -moz-border-radius:0; }
#navigation ul.menu li.expanded ul.menu li a:hover { color: #ffffff; }
/* 3rd, 4th, 5th, (...) level */
#navigation ul.menu li.expanded ul ul { display: none; left: 190px; top:0; }
Thanks to Blue Masters theme for the original code which I've changed a bit.
Comment #8
MiBe CreditAttribution: MiBe commentedThanks!
Looks good but i have a little issue.
My menu looks like this:
- Node 1
- Node 2 (child: - Node 3)
If I am on node 2 or node 3 everything went fine and the dropdown menu appears.
But if i am on my homesite (node 1) I can only click on node 2.
Node 3 remains hidden.
Where can I change this behaviour?
Comment #9
tumbledown100 CreditAttribution: tumbledown100 commentedHave you checked 'show as expanded' on the menu edit page for node/2? All pages that have children must have this checked.
Comment #10
MiBe CreditAttribution: MiBe commentedThanks a lot.
I haven't seen this option. Now it works fine - as it should be.
Comment #11
phb CreditAttribution: phb commentedDefinitly one of the best themes out there. Great work!
Still I would love to see support for two or multilevel menues. Any plans to do so?
Comment #12
alxs CreditAttribution: alxs commentedBig thanks to tumbledown100 for his code !! It work very well !!
I had just a problem to display "inline" the first menu with IE. I finally found a solution on internet.
Just replace the "#navigation ul.menu li ...." code with this on :
#navigation ul.menu li {
display:inline-block;
margin:0;
list-style:none;
background-image:url(images/menu_divider.jpg);
background-repeat:no-repeat;
background-position:top left;
text-align:center;
zoom: 1;
*display:inline;
padding:0;
}
I'm really not an CSS expert, so it's probably possible to do better, but at least it work...
Comment #13
jbergeron CreditAttribution: jbergeron commentedI am having a problem getting this to work in IE. I implemented the fix that makes it inline, but the levels below never show up when I scroll over. Works great in FF, of course it's IE that's being difficult!
Comment #14
tzt20 CreditAttribution: tzt20 commentedThanks so much for this code, worked great!
Comment #15
stBorchertIssue cleanup.
Comment #16
huuc CreditAttribution: huuc commentedhi, I know the topic is cleared but when I changed the code exactly as you are, sidebar first region is shifted to bottom of the content. I am a newbie of CSS, could you please help some way? thanks.
Comment #17
kspal CreditAttribution: kspal commentedMy little contribution: the code proposed by tumbledown100 works (thank you!) but is language-neutral and so does not work for multi-language site.
To correct this, rather use the code below for page.tpl.php, i.e on line 53 of page.tpl.php, change
to
Comment #18
zerocool22 CreditAttribution: zerocool22 commentedCan this be adjusted so this works on the horizontal menu as well? Now it only works on the side vertical menus.
Thanks