Japh

Web developer, technologist, innovator. Wptuts+ Site Editor and WordPress Evangelist @ Envato. I love the internet.

June 18, 2010 11:21 pm

Quick WordPress 3.0 Menu issue check

So WordPress 3.0 is out, and it’s awesome!

However… I think I may have already come across a bug in it’s new menus, and I’d like a hand checking if I’m right, or just making things up.

You can help me check by doing the following:

  1. Setup a fresh blog with WordPress 3.0
  2. Create a new menu, and give it a name like “Main Menu”
  3. In the Twenty Ten theme, edit the header.php file, and in the function call for wp_nav_menu, add ‘menu’ => ‘Main Menu’
    i.e. change this: wp_nav_menu( array( ‘container_class’ => ‘menu-header’, ‘theme_location’ => ‘primary’ ) );
    to this: wp_nav_menu( array( ‘menu’ => ‘Main Menu’, ‘container_class’ => ‘menu-header’, ‘theme_location’ => ‘primary’ ) );
  4. Now check if you can still see the sub-pages when hovering over menu items on the blog

Problem I’ve discovered (maybe) seems to be that the menus don’t properly respect $depth.  Or perhaps you won’t have the problem at all, and I’ve just broken something somewhere!  :)

Let me know your results if you do try it.