Sunday, August 29, 2010

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>
Share and Enjoy:
  • Print
  • Digg
  • Sphinn
  • del.icio.us
  • Facebook
  • Mixx
  • Google Bookmarks
  • FriendFeed
  • Netvibes
  • Reddit
  • RSS
  • Suggest to Techmeme via Twitter
  • Tumblr
  • Twitter
  • Twitthis
  • Blogosphere News
  • email
  • LinkedIn
  • Linkter
  • Live
  • MyShare
  • MySpace
  • Ping.fm
  • StumbleUpon
  • Technorati
  • Yahoo! Bookmarks
  • Yahoo! Buzz

Related posts:

  1. Free Wordpress Theme: wz-SimpleArt
  2. Wordpress theme: Beauty Style
  3. free wordpress theme pack 1
  4. Wordpress theme: Koi Theme
  5. WordPress theme: OneRoom

Speak Your Mind

Tell us what you're thinking...
and oh, if you want a pic to show with your comment, go get a gravatar!

SEO Powered by Platinum SEO from Techblissonline