WordPress TwentyFifteen and Bootstrap

Wondering why the link disappears if you do click a dropdown-toggle?

in functions.php comment out:

wp_localize_script( 'twentyfifteen-script', 'screenReaderText', array(
'expand' => '' . __( 'expand child menu', 'twentyfifteen' ) . '',
'collapse' => '' . __( 'collapse child menu', 'twentyfifteen' ) . '',
) );

and the following in functions.js

$( '.main-navigation .menu-item-has-children > a' ).after( '<button class="dropdown-toggle" aria-expanded="false">' + screenReaderText.expand + '</button>' );

and because that leads to an error about screnReaderText not being defined, comment out the following while you are at it in functions.js:

_this.html( _this.html() === screenReaderText.expand ? screenReaderText.collapse : screenReaderText.expand );

No Comments

Post a Comment