0

I love the mmenu jQuery plugin, but I'd like to be able to make it "fixed" at the top when scrolling the page. Looks like by adding the style="position: fixed;top: 0;width: 100%;z-index:10000" doesn't make the trick for me, since once I click on it, it gets lowered on the right side instead to be kept at the top, and if you have scrolled down, it disappears!

I have created the following two test pages, for you to show what's I am testing:

Regular version (not fixed): http://www.virtualsheetmusic.com/zmmenutest1.html

Fixed version (not working as it should): http://www.virtualsheetmusic.com/zmmenutest2.html

Ideas? How to make it "fixed at the top" easily and consistently?

Thanks in advance to anyone.

Best, Fab.

Fabrizio Ferrari
  • 869
  • 2
  • 12
  • 25

2 Answers2

0

the bug maybe in MAIN_speed_min.css

#content {
   margin-top: 15px;
}

just add new style on #content

  • I have changed the ID of the previously named "content" DIV, and at least the top menu doesn't get lowered now, but if I scroll down, and then I click the top menu to open the left side, the menu is still disappearing (http://www.virtualsheetmusic.com/zmmenutest3.html) Ideas? Thanks! – Fabrizio Ferrari Nov 04 '14 at 19:34
  • Problem solved guys, I must have missed the option to handle "fixed" elements, just added the suggested JS (http://mmenu.frebsite.nl/documentation/addons/fixed-elements.html) and FixedTop class to my header, and it works fine! – Fabrizio Ferrari Nov 04 '14 at 23:21
0

just add class name Fixed where that you write for posstion fixed example:

<nav class="header Fixed">
 <ul>
   <li>Home</li>
</ul>
</nav>

/// in css/

.header{
  position:fixed,
  top: 0px;
  left:0px
}