Wordpress 3.0: Make your theme compatible with WordPress 3.0 menus
April 29, 2010 by admin · Leave a Comment
WordPress 3.0 is going to feature a totally new menu system, which will allow users to add only the desired pages, add categories, and more. Good news for theme developers; adding WP 3.0 menu support to your themes is extremely easy.
To do so, open functions.php and add the following line:
<pre>add_theme_support( 'nav-menus' );</pre>
Once added, you can use the brand new wp_nav_menu() function in your theme files:
<pre>wp_nav_menu('sort_column=menu_order&container_class=navigation');</pre>
Related posts: