Navigation
This is archived content. Visit our new forum.

Tagged: 

  • Author
    Posts
  • #1148776
    macayla
    Participant

    Hello,

    I’d like to center the navbar menu, but only on one page. I am using

    .page-id-2 .x-navbar .x-brand {
    display: none;
    }

    to hide the logo on my home page, and I’d like the menu to be centered.
    url, http://www.sattvadubuque.com

    thanks in advance,

    #1149171
    Rue Nel
    Moderator

    Hi There,

    Thanks for writing in! To center the navbar menu in your homepage, please add the following css code in the customizer, Appearance > Customize > Custom > CSS

    .page-id-2 .masthead-inline .desktop .x-nav {
        display: block;
        float: none;    
    }
    
    .page-id-2 .masthead-inline {
        text-align: center;
        display: block;
        margin: 0 auto;
        width: auto;
    }
    
    .page-id-2 .masthead-inline .x-nav-wrap.desktop {
        display: inline-block;
    }

    We would loved to know if this has work for you. Thank you.

    #1149253
    macayla
    Participant

    Yes! Thank you! The only problem is that now the menu doesn’t disappear when the screen size shrinks. The collapsible menu appears, but the menu doesn’t disappear.

    #1149345
    Christopher
    Moderator

    Hi there,

    Please update this code :

    .page-id-2 .masthead-inline .x-nav-wrap.desktop {
        display: inline-block;
    }

    To :

    @media (min-width:979px){
    .page-id-2 .masthead-inline .x-nav-wrap.desktop {
        display: inline-block;
    }
    }

    Hope it helps.

    #1152174
    macayla
    Participant

    Yes! Thank you 🙂

    #1152256
    Joao
    Moderator

    You are welcome 🙂

    Let us know if you need help with anything else.

    Joao

  • <script> jQuery(function($){ $("#no-reply-1148776 .bbp-template-notice, .bbp-no-topic .bbp-template-notice").removeClass('bbp-template-notice'); }); </script>