Responsive Ad Area

Share This Post


WP Bootstrap Navwalker Mobile Menu Not Working

I am using the WP bootstrap navwalker for my wordpress site. The desktop version of the menu is working properly but there’s some problem with the hamburger menu. The hamburger menu is showing up but the collapse thing is not working.
Here’s my Navwalker Menu:

    <nav class="navbar navbar-expand-lg navbar-light bg-color">
  <button class="navbar-toggler ml-auto" type="button" data-toggle="collapse" data-target="#navbarSupportedContent" aria-controls="navbarSupportedContent" aria-expanded="false" aria-label="Toggle navigation">
    <i class="fas fa-bars"></i>

  <div class="collapse navbar-collapse" id="navbarSupportedContent">
    <ul class="navbar-nav mx-auto">
      wp_nav_menu( array(
    'theme_location'  => 'primary',
    'depth'           => 2, // 1 = no dropdowns, 2 = with dropdowns.
    'container'       => 'div',
    'container_class' => 'collapse navbar-collapse',
    'container_id'    => 'bs-example-navbar-collapse-1',
    'menu_class'      => 'navbar-nav mr-auto',
    'fallback_cb'     => 'WP_Bootstrap_Navwalker::fallback',
    'walker'          => new WP_Bootstrap_Navwalker(),
) );



and here’s my enqueued scripts:


    //Theme Support
    function wpb_theme_setup(){
        //NAV Menus
            'primary' =>__('Primary Menu')

        //CSS Files
        wp_enqueue_style('font-awesome', '//');

        wp_enqueue_style('bootstrap', '//');

        wp_enqueue_style('owl-carasoul', '//');

        wp_enqueue_style( 'baguette-box', '//');

        wp_enqueue_style('main-css', get_stylesheet_uri(), NULL, microtime(), false);


        wp_enqueue_script('jquery', '//', NULL,'1.0', false);

        wp_enqueue_script('owl', '//', NULL, '1.0', true);

        wp_enqueue_script('bootstrap-js', '//', NULL, '4.1.3', true);

        wp_enqueue_script('baguette-js', '//', NULL, '1.10.0', false);


    add_action('after_setup_theme', 'wpb_theme_setup');

WP Bootstrap Navwalker Mobile Menu Not Working
WP Bootstrap Navwalker Mobile Menu Not Working

Share This Post

Leave a Reply

Your email address will not be Publishedd. Required fields are marked *

You may use these HTML tags and attributes: <a href="" title=""> <abbr title=""> <acronym title=""> <b> <blockquote cite=""> <cite> <code> <del datetime=""> <em> <i> <q cite=""> <s> <strike> <strong>

Skip to toolbar