Hello,
I tried to add secondary menu functionality in the functions.php of Unite theme:
// This theme uses wp_nav_menu() in one location.
register_nav_menus( array(
'primary' => __( 'Primary Menu', 'unite' ),
'secondary' => __( 'Secondary Menu', 'unite' ),
'footer-links' => __( 'Footer Links', 'unite' ) // secondary nav in footer
) );
and I created child theme and I have this file: header-2.php in it, since I need different header picture and different menu nav. So to display this secondary menu I added:
<?php
wp_nav_menu( array(
'theme_location' => 'secondary',
'depth' => 2,
'container' => 'div',
'container_class' => 'collapse navbar-collapse navbar-ex1-collapse',
'menu_class' => 'nav navbar-nav',
'fallback_cb' => 'wp_bootstrap_navwalker::fallback',
'walker' => new wp_bootstrap_navwalker())
);
?>
I have created the menu set for this secondary menu in WordPress Dashboard, but somehow it is still showing the primary menu.
I wonder if I should add this header-2.php file inside the Unite theme folder instead of my child theme folder?
Any idea of how to solve this problem?
Thank you!
~ A u d e e