Not working
I am using navwalker in lots of my projects. Currently i am facing this unexpected error and also not founding any fix for this. Hope here anyone provide me a better solution.
I am using bootstrap 3.3.4. Using all the step to include nav walker in functions.php
Calling the navwalker:
<?php
wp_nav_menu( array(
'menu' => 'primary',
'theme_location' => '',
'depth' => 2,
'container' => 'div',
'container_class' => 'navbar-collapse collapse',
'container_id' => 'navbar',
'menu_class' => 'nav navbar-nav navbar-right wow slideInRight',
'fallback_cb' => 'wp_bootstrap_navwalker::fallback',
'walker' => new wp_bootstrap_navwalker())
);
?>
I am receiving the error on view. its replace the nav title. for e.g: Page 1 having 3 child items. Its is replace the page 1 to "expand child menu" and second click "collapse child menu".

Very interesting. This must be coming from a conflicting script as those phrases are not included in WordPress's default menu functions or wp-bootstrap-navwalker
Hi there,
the problem is in the functions.js of the Wordpress Theme.
This worked for me (Line27):
$( '.dropdown-toggle' ).click( function( e ) { var _this = $( this ); e.preventDefault(); _this.toggleClass( 'toggle-on' ); _this.next( '.children, .sub-menu' ).toggleClass( 'toggled-on' ); _this.attr( 'aria-expanded', _this.attr( 'aria-expanded' ) === 'false' ? 'true' : 'false' ); //_this.html( _this.html() === screenReaderText.expand ? screenReaderText.collapse : screenReaderText.expand ); } );