Menu icon Foundation
Nav menu showing double on Mobile

Hey, everyone!

I just noticed an issue on a site I'm finishing up regarding the fixed nav menu on mobile.

Once I scroll down the page a bit, the fixed nav bar shows at the top and also shows randomly in the middle of the page. It doesn't happen every time -- mainly occurring once I've scrolled down some, opened the correctly-positioned nav bar, and chosen a menu item (they are anchor links to a section on the one page). The page will scroll to the new section and the 2nd menu will then pop onto the screen. Like I said, it's not every single time, which seems rather odd. Only one menu in my code, also.

Any idea what could be causing this? Doesn't occur on desktop at all.

Many thanks for any ideas.

mobilemenufixednavbarissue

Hey, everyone!

I just noticed an issue on a site I'm finishing up regarding the fixed nav menu on mobile.

Once I scroll down the page a bit, the fixed nav bar shows at the top and also shows randomly in the middle of the page. It doesn't happen every time -- mainly occurring once I've scrolled down some, opened the correctly-positioned nav bar, and chosen a menu item (they are anchor links to a section on the one page). The page will scroll to the new section and the 2nd menu will then pop onto the screen. Like I said, it's not every single time, which seems rather odd. Only one menu in my code, also.

Any idea what could be causing this? Doesn't occur on desktop at all.

Many thanks for any ideas.

Rafi Benkual almost 4 years ago

It's not happening on the docs example. Do you have a link to the site so we can help you more?

Scott Haney almost 4 years ago

Hey, Rafi.

As always, thanks for the quick response (do you ever take a break from helping folks on here?!).

Unfortunately, even though I knew a link would help diagnose the issue, I don't have it online quite yet -- local machine only so far. I'm going to do a bit of tidying up in my code and keep checking to see if it's still occurring. I just went ahead and posted the question tonight in case anyone else had encountered the same type of odd behavior. Once I get it to a server, I'll definitely post a link if I'm still seeing the problem.

Thanks again!

Rafi Benkual almost 4 years ago

Ok, we'd like to see it to help you more. If anyone else has experienced this please let us know.

I checked on GitHub but no reports there.