Enabling Menus

Navigation menus are a big new feature in version 3.0. If you want to support them in your new theme, or if you're modifying an older theme for 3.0, you'll need to add the code in Listing 6-33 to your theme files.

Listing 6-33. Enabling navigation menus

// in functions.php: add_theme_support('nav-menus');

// wherever your current menu tag is located, replace it with: <?php wp_nav_menu( 'sort_column=menu_order' ); ?>

If you prefer, you can use the new Navigation Menu widget rather than placing the menu tag in your templates.

0 0

Post a comment