Adding a second menu to the Speaky WordPress theme from WPBeginner, even though this tutorial is for adding a second menu specifically to the TwentyTen WordPress theme.

Tutorial: http://digitalraindrops.net/2010/08/the-second-menu/

Files affected:

  1. functions.php
  2. header.php
  3. navigation-2.php (new file)
  4. style.css

Note: Since I didn’t want the second menu to look different from the main menu, as the tutorial instructs, I altered some of the PHP code in the navigation-2.php file.

Change:

<?php /* Start add our second page menu */ ?>
<div id=”pagemenu” role=”navigation”>
<?php wp_nav_menu( array( ‘container_class’ => ‘page-header’, ‘menu_class’ => ‘page-menu’, ‘theme_location’ => ‘secondary’, ‘depth’ => 0, ‘fallback_cb’ => ” ) ); ?>
</div>
<?php /* End lower page menu */ ?>

To:

<?php /* Start add our second page menu */ ?>
<div id=”access” role=”navigation”>
<?php wp_nav_menu( array( ‘container_class’ => ‘menu-header’, ‘theme_location’ => ‘secondary’, ‘fallback_cb’ => ” ) ); ?>
</div>
<?php /* End lower page menu */ ?>