cc licensed flickr photo shared by ElDave The main navigation of most WordPress sites is driven by cycling through all of the content that are WordPress pages– which is nice, but sometimes you have content that you don;t want cluttering the navbar. Or maybe you want to insert something that is not a Page into the navbar. I’ve been amazed that so few people seem to know how to subvert it, and below is a little trick I use when I want to wedge some other kind of WordPress content into the navbar by Pages process. Mostly this is in your HEAD… I mean the header.php file of your templates that generates it as an Unordered List: <div id="nav"> <ul> <li class="<?php if (is_home()) {echo 'page_item current_page_item'; } ?>"> <a href="<?php echo get_settings('home'); ?>/">Home</a></li> <?php wp_list_pages('title_li' ); ?> </ul> </div> The first li item creates the Home link, and in [...]
(see the full barking...)CogBlogged Tagged ‘theme’
WordPress Theme Hacking (fun): Ninmah’s Postcards
My colleague Rachel Smith presented a nice little WordPress challenge to re-create what she had done previously as old skool manual HTML page updating into her WordPress blog (see Postcards back through time). In the spirit of previous documentation of WordPress Theme hacking, here is the under the hood things I did, some variations on ones I have written previously WordPressing Dissected: Pachyderm Services and Making of a New Site: NMC Virtual Worlds. This current write up includes a custom category template, direct database querying, custom fields, and maybe a little elbow grease. Firstly, the original site of Rachel’s postcards features her original artwork, with the most recent one at the top, and icon links to previous works below. I would guess creating a new one is making a new HTML page, copying some source code to the top of the index, and updating the icons below. Maybe it’s not [...]
(see the full barking...)



