Registration is open at the official WordCamp site. Don’t forget to tell them your shirt size.
One of the coolest new features in WordPress 3.0 is the ability to add custom menus. In this post we’ll walk you through the process of adding custom menu support to your existing them as well as setting up the custom menus in the admin section.
1. Add the register_nav_menus function to your functions.php file.
In your functions.php file, add the following code:
'main-menu' => __( 'Main Menu' ),
This will allow your theme to recognize and register a custom navigation menu.
2. Replace the code for your current navigation menu (in your header.php file) with wp_nav_menu.
Open your header.php file and find the section that calls up your navigation menu. It may look something like this:
<?php wp_list_pages(); ?>
Replace that code with this one:
<?php wp_nav_menu( array( 'theme_location' => 'main-menu' ) ); ?>
Using the above code will replace your existing navigation menu with one you specify in the new Menus section (see below).
3. Log in to the admin area of your WordPress site and go to Appearance > Menus.
4. Create a new menu. Give your menu a name (this will not be displayed on your site) and add links by choosing from your pages, categories, or custom URLs. Once you’ve added all the links you want to include in your navigation menu, click “Save Menu.”
5. In the top left of the Menus section, you will see a box labeled “Theme Locations” which should say the following: Your theme supports 1 menu. Select which menu you would like to use. In the drop-down, choose the menu you just created and hit “Save.”
That’s it! You’ve just set up custom menus for your WordPress theme. You can add, delete or re-order your menu items any time you want.
Additionally, you can add custom menus to your sidebar, too – without touching a single line of code. Just add a new custom menu by clicking the plus sign next to your existing menu. Once you’ve got your new menu named and some menu items in place, go to Appearance > Widgets and choose the Custom Menu widget. Drag it to your sidebar, give it a name, and you’re ready to roll!
Questions? Problems? Leave a comment and we’ll do our best to help you out.
Jessica will be speaking at WordCamp Portland!
The full schedule hasn’t been announced yet, but the event is
September 18-19 2010 at Webtrends in Portland, OR
Business Blogging for Non-Writers
Learn to make the most of your business blog, even if writing isn’t your strong suit.
Check it out if you are in the area.
Hope to see you there!
We (well Matt anyway) will be attending SXSWi 2010 again this year down in Austin, TX.
Tons of great talks for WordPress designers.
Hope to see you there!
WordPress 2.9 includes some new photo manipulation features, basic cropping and the like.
Aaron Hockley, (blogger, photographer and the Tech Editor for our book) has an excellent post walking through some of the upcoming features in WordPress 2.9 on his site Social Photo Talk.
Check out his post on the new WordPress Photo Image Features here.
Over on the WordPress blog, Matt Mullenweg announced that WordPress won the 2009 Open Source CMS award. Congratulations to all the hard working folks who make WordPress happen.
Matt’s post about winning the award can be found here.
This is the first time that WordPress has won that award, and I think Matt explained the significance very well.
“Every day thousands of new people are embracing WordPress to power not just their blogs but entire sites and communities without compromising on usability or scalability (as would be the case with a legacy CMS). Every member of the WordPress community, from core developer to beginning user, should be proud to be part of this momentum: congratulations to us all!”
So, congrats to the WordPress team on a well deserved acknowledgment.
Itching for a copy of our new book, the WordPress Visual QuickStart Guide? Of course you are, and we’re here to help.
Our No wpautop Pages plugin for WordPress (used on this site) is now available through the WordPress Codex.
What this does is really pretty simple.
WordPress uses a built-in function called wpautop, that adds <p> tags and new lines to content that you put into WordPress. On the whole this works great. When you edit a blog post it lets you write it like an email rather than a block of HTML.
But what happens if you want to write your own HTML? Well, you can use the HTML editor obviously, but the content is still run through the wpautop filter before being sent to the browser, which can cause problems.
So we wrote a quick little function that disables wpautop for Pages, but leaves it intact for posts. Best of both worlds for us.
For more information on the plugin, check out the No wpautop Pages plugin page.
This is a time lapse video of a building that was demolished near our office in downtown Portland, Oregon in May, 2008.
It can be really convenient to post from e-mail, especially if you’re
on the go! Just remember a couple of things to make sure you don’t run
into any problems.
1. Attachments don’t work well over e-mail, so limit yourself to text
2. Keep your formatting to a minimum
3. Don’t cc: anyone on your blog post e-mails; the address is a secret!