Support » Plugin: My Bootstrap Menu » What PHP code needs to be in header file to make the menu function?

  • Resolved koniahin

    (@koniahin)


    If I enable and assign the bootstrap menu to the site’s main menu, the menu displays positioned correctly, but I’m also getting the website’s logo, slogan and reserved space for the original menu. I have reviewed the template and these items are/were controlled by the original menu, not aside. So the question, what is the nav css and php code to activate the bootstrap menu only?

    <nav class=”???”>
    <?php

    ?>
    </nav>

    https://wordpress.org/plugins/my-bootstrap-menu/

Viewing 2 replies - 1 through 2 (of 2 total)
  • Thread Starter koniahin

    (@koniahin)

    N’ere mind, wasn’t paying attention. There was a header div which was forcing display of the problem children. I set it to display:none just to see and it worked.

    The nav code I am using is:

    <nav>
    <div class=”container”>
    <?php
    wp_nav_menu( array(
    ‘theme_location’ => ‘primary’,
    ‘depth’ => 2,
    ‘container’ => ‘div’,
    ‘fallback_cb’ => ‘wp_bootstrap_navwalker::fallback’,
    ‘walker’ => new wp_bootstrap_navwalker())
    );
    ?>
    </div>
    </nav>

    Plugin Author codetoolbox

    (@codetoolbox)

    Hi,

    Glad to hear your issue is resolved!

    Just noticing you have: ‘walker’ => new wp_bootstrap_navwalker() … Unless you’re using this for a specific reason it can be removed, it’s not required for My Bootstrap Menu.

    Good luck with your site.

Viewing 2 replies - 1 through 2 (of 2 total)
  • The topic ‘What PHP code needs to be in header file to make the menu function?’ is closed to new replies.