• Resolved eztune

    (@eztune)


    My sticky menu works for the menu items, but the menu background is transparent. How can I make the menu background sticky or add a colored background to the sticky menu? (http://www.familytiez.net)

    Thanks,
    Marty

Viewing 7 replies - 1 through 7 (of 7 total)
  • Hi Marty, thanks for trying my plugin. 🙂

    I would suggest that instead of using “#main-menu” as the sticky element, you should use “.et_pb_fullwidth_menu“. It should have the same sticky effect, but it will have the colored background.

    Give that a try and let me know if that works!

    Thread Starter eztune

    (@eztune)

    That certainly did the trick. It now works perfectly. Still, how can I determine what the proper sticky element string I use? Guidance would profit all of us, please. How do we locate the proper string?

    • This reply was modified 9 years, 3 months ago by eztune.

    It’s difficult to give a failsafe method of finding the proper element, to be honest, because every web site is different.

    What it comes down to, is that you first locate the element (which you did), but that you also check if maybe the parent element (or grandparent, or even higher) would be better, if there are some styles applied to those that you also want to see in the sticky element. In your case, #main-menu works, but the background color was applied to one of the parents, so that would be a better one to pick.

    Like I said, it’s a little difficult to explain, but it’s something you get a feel for, the more you do it (or just the more you create web sites).

    Hope that makes sense….at least a little?

    Mark.

    In response to your earlier post:

    “I would suggest that instead of using “#main-menu” as the sticky element, you should use “.et_pb_fullwidth_menu“. It should have the same sticky effect, but it will have the colored background.”

    What do you mean by “you should use “.et_pb_fullwidth_menu“”?

    I’m using Bretheon theme, my menu name is “mainmenu” and I currently have “#menu” as my sticky item in the sticky menu settings which works.

    The web site is http://www.ellerbecknarrowboats.co.uk and i’d like a solid background to the menu when it sticks to the top of the page when scrolling down.

    Thanks in advance for your help.

    Lucien

    << What do you mean by “you should use “.et_pb_fullwidth_menu“”? >>

    This was something that referred to the http://www.familytiez.net specifically — it wasn’t meant to be a general comment that would work for all sites. You can ignore it for your site.

    In order to add a background color to your menu, you can add this CSS code:

    #Header #menu {
        background: #ffffff;
    }

    Hope this helps!

    Thank you Mark

    This worked a treat!!!

    Lucien

    Glad I could help! 🙂

Viewing 7 replies - 1 through 7 (of 7 total)

The topic ‘Sticky Menu Background’ is closed to new replies.