[Resolved] sticky menu – use diffrent menu than main menu

Home Forums Support [Resolved] sticky menu – use diffrent menu than main menu

Home Forums Support sticky menu – use diffrent menu than main menu

Viewing 6 posts - 1 through 6 (of 6 total)
  • Author
    Posts
  • #1450762
    Anders Nielsen

    Hi there.. I created a video.

    I’m trying to use a diffrent menu, for the sticky menu – is that possible?

    #1450899
    David
    Staff
    Customer Support

    Hi there,

    tricky one.
    My thoughts are:

    1. Create a menu that includes all the Menu items for sticky and static.
    2. Give the menu items you want displayed on the Sticky Nav only a class of: sticky-item
    How to: https://docs.generatepress.com/article/using-the-wordpress-menu-builder/#custom-classes
    3. Then add this CSS to your site:

    
    /* Sticky menu display only sticky-item */
    .main-navigation.is_stuck .main-nav ul li:not(.sticky-item) {
    	display: none;
    }
    /* Static menu remove sticky-item */
    .main-navigation:not(.is_stuck) .main-nav ul li.sticky-item {
    	display: none;
    }
    #1451155
    Anders Nielsen

    It’s working…. πŸ™‚

    Thanks

    Now I just need to figure out – how make a button in the sticky menu.

    #1451198
    Leo
    Staff
    Customer Support

    So button in sticky menu only?

    You should be able to use this method and add the same class as David mentioned above:
    https://docs.generatepress.com/article/adding-buttons-navigation/

    #1451645
    Anders Nielsen

    Yes it works πŸ™‚

    Documentation needs a !important for line-height. πŸ™‚

    #1452512
    Leo
    Staff
    Customer Support

    Hmm maybe for the sticky navigation part.

    Will take a look πŸ™‚

Viewing 6 posts - 1 through 6 (of 6 total)
  • You must be logged in to reply to this topic.