Archive for the 'snippets' Category
« Previous Entries
Thursday, September 4th, 2008
Referring back to an old post on using a Dynamic Body ID in WordPress you might notice that anything in WordPress that is not a page is actually a part of the blog – including search, single, archive and the posts page. The following code should refresh your memory on how to use a dyanamic body ID. If it’s not a page then give the body an ID of News, else if it is a page with the following titles then the appropriate body ID of the title is used, otherwise just insert the body tag.
<?php if ((!is_page())) { ?>
<body id="News">
<?php } elseif ((is_page('Home')) || (is_page('Studio')) || (is_page('Support')) || (is_page('About')) || (is_page('Contact')))
{ ?>
<body id="<?php the_title(); ?>">
<?php } else { ?>
<body>
<?php } ?>
Read the rest of this entry »
Posted in snippets, wordpress | Comments Off
« Previous Entries
About the Author
My name is Steven Clark and my passions are business, web development, photography and writing. My current CV [PDF 775KB] discusses relevant work history and interests. Currently I'm in the second half of a post-graduate university degree of MBA (Journalism and Media Studies) at the University of Tasmania.
Lo and behold I now happen to inhabit the realms of Facebook and Twitter so see you over there.
My fine art photography is available online at Steven Clark Studio. You may also enjoy my photo blog Walk a Mile in my Shoes.
Site Supporters
Hosted by Brett Drinkwater at Tashosting who is always there at the other end of my every inconvenient question and technical crisis. Brett's local community support for us over the last five years is greatly appreciated.