<?xml version="1.0" encoding="UTF-8"?>
<rss version="2.0"
	xmlns:content="http://purl.org/rss/1.0/modules/content/"
	xmlns:wfw="http://wellformedweb.org/CommentAPI/"
	xmlns:dc="http://purl.org/dc/elements/1.1/"
	xmlns:atom="http://www.w3.org/2005/Atom"
	xmlns:sy="http://purl.org/rss/1.0/modules/syndication/"
	xmlns:slash="http://purl.org/rss/1.0/modules/slash/"
	>

<channel>
	<title>Tammy Hart Designs &#187; Tutorials</title>
	<atom:link href="http://www.tammyhartdesigns.com/tutorials/feed/" rel="self" type="application/rss+xml" />
	<link>http://www.tammyhartdesigns.com</link>
	<description>Web Designer &#38; Custom WordPress  Theme Developer in Birmingham, AL</description>
	<lastBuildDate>Mon, 30 Jan 2012 17:58:44 +0000</lastBuildDate>
	<language>en</language>
	<sy:updatePeriod>hourly</sy:updatePeriod>
	<sy:updateFrequency>1</sy:updateFrequency>
	<generator>http://wordpress.org/?v=3.3.1</generator>
<xhtml:meta xmlns:xhtml="http://www.w3.org/1999/xhtml" name="robots" content="noindex" />
		<item>
		<title>Reusable Custom Meta Boxes Part 3: Extra&#160;Fields</title>
		<link>http://www.tammyhartdesigns.com/wordpress/reusable-custom-meta-boxes-part-3-extra-fields/?utm_source=rss&#038;utm_medium=rss&#038;utm_campaign=reusable-custom-meta-boxes-part-3-extra-fields</link>
		<comments>http://www.tammyhartdesigns.com/wordpress/reusable-custom-meta-boxes-part-3-extra-fields/#comments</comments>
		<pubDate>Tue, 10 Jan 2012 20:06:28 +0000</pubDate>
		<dc:creator>Tammy Hart</dc:creator>
				<category><![CDATA[Tutorials]]></category>
		<category><![CDATA[WordPress]]></category>

		<guid isPermaLink="false">http://www.tammyhartdesigns.com/?p=2423</guid>
		<description><![CDATA[In Part 1 and Part 2 of our custom meta box template tutorial series, we learned how to create a field array to loop through and create a custom meta box with your standard fields. Now let’s throw in a bit of JavaScript for some fancy, but highly useful fields. Finish Reading at WPTuts+]]></description>
			<content:encoded><![CDATA[<p><img class="alignright size-full wp-image-2396" title="metabox_0" src="http://www.tammyhartdesigns.com/wp-content/uploads/2011/12/metabox_0.jpg" alt="" width="200" height="200" />In <a href="http://www.tammyhartdesigns.com/wordpress/reusable-custom-meta-boxes-part-1-intro-and-basic-fields/">Part 1</a> and <a href="http://www.tammyhartdesigns.com/wordpress/reusable-custom-meta-boxes-part-2-advanced-fields/">Part 2</a> of our custom meta box template tutorial series, we learned how to create a field array to loop through and create a custom meta box with your standard fields. Now let’s throw in a bit of JavaScript for some fancy, but highly useful fields.</p>
<p><a class="button" href="http://wp.tutsplus.com/tutorials/reusable-custom-meta-boxes-part-3-extra-fields/">Finish Reading at WPTuts+</a></p>
]]></content:encoded>
			<wfw:commentRss>http://www.tammyhartdesigns.com/wordpress/reusable-custom-meta-boxes-part-3-extra-fields/feed/</wfw:commentRss>
		<slash:comments>18</slash:comments>
		</item>
		<item>
		<title>Reusable Custom Meta Boxes Part 2: Advanced&#160;Fields</title>
		<link>http://www.tammyhartdesigns.com/wordpress/reusable-custom-meta-boxes-part-2-advanced-fields/?utm_source=rss&#038;utm_medium=rss&#038;utm_campaign=reusable-custom-meta-boxes-part-2-advanced-fields</link>
		<comments>http://www.tammyhartdesigns.com/wordpress/reusable-custom-meta-boxes-part-2-advanced-fields/#comments</comments>
		<pubDate>Thu, 15 Dec 2011 19:58:44 +0000</pubDate>
		<dc:creator>Tammy Hart</dc:creator>
				<category><![CDATA[Tutorials]]></category>
		<category><![CDATA[WordPress]]></category>

		<guid isPermaLink="false">http://www.tammyhartdesigns.com/?p=2410</guid>
		<description><![CDATA[In Part 1 of our custom meta box template tutorial series, we covered how to set up a custom meta box that loops through an array of fields and outputs each one with the necessary html for various types of form fields. Now we’re ready to start adding a few advanced items to the array and switch&#8230;]]></description>
			<content:encoded><![CDATA[<p><img src="http://www.tammyhartdesigns.com/wp-content/uploads/2011/12/metabox_0.jpg" alt="" title="metabox_0" width="200" height="200" class="alignright size-full wp-image-2396" />In <a href="http://www.tammyhartdesigns.com/wordpress/reusable-custom-meta-boxes-part-1-intro-and-basic-fields/">Part 1 of our custom meta box template tutorial</a> series, we covered how to set up a custom meta box that loops through an array of fields and outputs each one with the necessary html for various types of form fields. Now we’re ready to start adding a few advanced items to the array and switch case.</p>
<p><a href="http://wp.tutsplus.com/tutorials/reusable-custom-meta-boxes-part-2-advanced-fields/" class="button">Finish Reading at WPtuts+</a></p>
]]></content:encoded>
			<wfw:commentRss>http://www.tammyhartdesigns.com/wordpress/reusable-custom-meta-boxes-part-2-advanced-fields/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>Reusable Custom Meta Boxes Part 1: Intro and Basic&#160;Fields</title>
		<link>http://www.tammyhartdesigns.com/wordpress/reusable-custom-meta-boxes-part-1-intro-and-basic-fields/?utm_source=rss&#038;utm_medium=rss&#038;utm_campaign=reusable-custom-meta-boxes-part-1-intro-and-basic-fields</link>
		<comments>http://www.tammyhartdesigns.com/wordpress/reusable-custom-meta-boxes-part-1-intro-and-basic-fields/#comments</comments>
		<pubDate>Sat, 10 Dec 2011 18:13:31 +0000</pubDate>
		<dc:creator>Tammy Hart</dc:creator>
				<category><![CDATA[Tutorials]]></category>
		<category><![CDATA[WordPress]]></category>

		<guid isPermaLink="false">http://www.tammyhartdesigns.com/?p=2393</guid>
		<description><![CDATA[There are a lot of tutorials on creating custom meta boxes, even just here on Wptuts, and it goes to show that having a good knowledge of these and a system for creating them is crucial to a successful WordPress theme or plugin project. In this series we won’t rehash what meta boxes are but instead we’ll create an&#8230;]]></description>
			<content:encoded><![CDATA[<p><img class="alignright size-full wp-image-2396" title="metabox_0" src="http://www.tammyhartdesigns.com/wp-content/uploads/2011/12/metabox_0.jpg" alt="" width="200" height="200" />There are a lot of tutorials on <a href="http://wp.tutsplus.com/tutorials/plugins/how-to-create-custom-wordpress-writemeta-boxes/">creating custom meta boxes</a>, even just here on Wptuts, and it goes to show that having a good knowledge of these and a system for creating them is crucial to a successful WordPress theme or plugin project. In this series we won’t rehash <a href="http://wp.tutsplus.com/tutorials/plugins/how-to-create-custom-wordpress-writemeta-boxes/">what meta boxes are</a> but instead<strong> we’ll create an easy system for plugging them into whatever your latest project is</strong> to keep your work moving consistently.</p>
<p><a class="button" href="http://wp.tutsplus.com/tutorials/reusable-custom-meta-boxes-part-1-intro-and-basic-fields/">Finish Reading at WPtuts+</a></p>
]]></content:encoded>
			<wfw:commentRss>http://www.tammyhartdesigns.com/wordpress/reusable-custom-meta-boxes-part-1-intro-and-basic-fields/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>WordPress Permalinks Best&#160;Practices</title>
		<link>http://www.tammyhartdesigns.com/wordpress/wordpress-permalinks-best-practices/?utm_source=rss&#038;utm_medium=rss&#038;utm_campaign=wordpress-permalinks-best-practices</link>
		<comments>http://www.tammyhartdesigns.com/wordpress/wordpress-permalinks-best-practices/#comments</comments>
		<pubDate>Mon, 10 May 2010 16:12:27 +0000</pubDate>
		<dc:creator>Tammy Hart</dc:creator>
				<category><![CDATA[Tutorials]]></category>
		<category><![CDATA[WordPress]]></category>

		<guid isPermaLink="false">http://tammyhartdesigns.com/?p=1194</guid>
		<description><![CDATA[Permalink is a combination of the words &#8220;permanent link&#8220;, similar to how blog is a combination of &#8220;web log&#8221;. A permalink simply means the&#160;URL&#160;to a page or post on your website/blog. There has been a lot of disucssion about the proper structure for permalinks, especially since the advent of &#8220;Pretty Permalinks&#8221;, and a lot of&#8230;]]></description>
			<content:encoded><![CDATA[<div id="attachment_1199" class="wp-caption alignright" style="width: 310px"><a class="nyroModal" href="http://www.tammyhartdesigns.com/wp-content/uploads/2010/05/permalinks.jpg"><img class="size-medium wp-image-1199" title="permalinks" src="http://tammyhartdesigns.com/core/wp-content/uploads/permalinks-300x245.jpg" alt="" width="300" height="245"></a><p class="wp-caption-text">Click to Enlarge</p></div>
<p>Permalink is a combination of the words &#8220;<a class="zem_slink freebase/en/permalink" title="Permalink" rel="wikipedia" href="http://en.wikipedia.org/wiki/Permalink">permanent link</a>&#8220;, similar to how blog is a combination of &#8220;web log&#8221;. A permalink simply means the&nbsp;URL&nbsp;to a page or post on your website/blog.</p>
<p>There has been a lot of disucssion about the proper structure for permalinks, especially since the advent of &#8220;Pretty Permalinks&#8221;, and a lot of people have their opinion on what the best structure is. This is my best advice when it comes to permalinks, and it&#8217;s a combination of advice from an SEO expert friend, and my experience with WordPress.</p>
<h2>Default Permalinks</h2>
<p>I&#8217;m not going to rehash all of the details about permalinks that you can find over at the <a href="http://codex.wordpress.org/Using_Permalinks">WordPress codex</a>, but let&#8217;s start by looking at the default permalinks which look something like this:</p>
<ul>
<li><strong>Post Permalink:</strong> <code>example.com/?p=123</code></li>
<li><strong>Page Permalink:</strong> <code>example.com/?page_id=123</code></li>
<li><strong>Category Permalink:</strong> <code>example.com/?cat=123</code></li>
<li><strong>Tag Permalink:</strong> <code>example.com/?tag=tag-name</code></li>
<li><strong>Archive Permalink:</strong> <code>example.com/?m=201005</code> or <code>example.com/?m=2010</code></li>
</ul>
<p>These seem simple enough, but as you can see, this is what is generally defined as an &#8220;ugly permalink&#8221;.</p>
<p><span id="more-1194"></span></p>
<h2>Suggested Permalink Structure</h2>
<p>There are a lot of different ways you can edit the way this looks, but the one that makes the most sense to users and to search engines is for the URL to make a path directly to the resulting page, the only interruption being a categorization for posts. These resulting permalinks will look like this:</p>
<ul>
<li><strong>Post Permalink:</strong> <code>example.com/cat-name/post-name</code></li>
<li><strong>Page Permalink:</strong> <code>example.com/page-name</code></li>
<li><strong>Category Permalink:</strong> <code>example.com/cat-name</code></li>
<li><strong>Tag Permalink:</strong> <code>example.com/tag-name</code></li>
<li><strong>Archive Permalink:</strong> <code>example.com/2010/05</code> or <code>example.com/2010</code></li>
</ul>
<p>To set your structures to this, use this as your custom structure: <code>/%category%/%postname%/</code> and then leave the tag and category bases blank.</p>
<p>Remember that words that come after your&nbsp;URL&nbsp;are going to look like directories, even though they aren&#8217;t really. For instance, you might look at the path to an image that looks like this: <code>example.com/mydesign/images/logo.jpg</code>. On your server, there is a public root directory after which there is a directory called &#8220;mydesign&#8221;, and then inside that there is a directory called &#8220;images&#8221;. In graphical user interfaces, these are generally represented as folders within folders. So if you have a permalink like this: <code>example.com/category/cat-name</code>, a search engine and even some users, are going to assume you have a directory on your server called &#8220;category&#8221; and then another called &#8220;cat-name&#8221;.</p>
<p>That being said, when you use my suggestion for your permalinks, and you have a post called &#8220;Hello World&#8221; in the category named &#8220;General&#8221; your permalink will be this: <code>example.com/general/hello-world</code>, and your category&#8217;s permalink will be &#8220;example.com/general&#8221;. This is good since when a search engine gets to the /general/ part of your permalink, it&#8217;s going to index that&nbsp;pseudo&nbsp;directory as well. Thanks to your permalink structure, that will result in a page with topics in that category, rather than a 404 error page, which isn&#8217;t a good thing for a search engine to find.</p>
<h2>Don&#8217;t Skip This: Remove Category and Tag Base</h2>
<p>By now, you&#8217;re probably noticing that your categories look like this: <code>example.com/category/cat-name</code>. By default, WordPress will insert a default category base of &#8220;category&#8221; and tag base of &#8220;tag&#8221;, but since the directories &#8220;category&#8221; and &#8220;tag&#8221; don&#8217;t exist we want to remove these. This is pretty simple to do with this plugin: <a href="http://wordpress.org/extend/plugins/wp-no-category-base/">WP No Category Base</a>.</p>
<h2>Search Permalinks</h2>
<p>It is noteworthy that no matter what your permalink structure is, your <strong>search permalink</strong> will always be the same: <code>example.com/?s=searchterm</code></p>
<div class="zemanta-pixie" style="margin-top: 10px; height: 15px;"><img class="zemanta-pixie-img" style="border: none; float: right;" src="http://img.zemanta.com/pixy.gif?x-id=6a67a7c7-28ad-4109-a396-f0e98bcb41e3" alt=""><span class="zem-script more-related more-info pretty-attribution"></span></div>
]]></content:encoded>
			<wfw:commentRss>http://www.tammyhartdesigns.com/wordpress/wordpress-permalinks-best-practices/feed/</wfw:commentRss>
		<slash:comments>8</slash:comments>
		</item>
		<item>
		<title>How to Add the Parent Category as a Class in&#160;body_class()</title>
		<link>http://www.tammyhartdesigns.com/wordpress/how-to-add-the-parent-category-class-to-body_class/?utm_source=rss&#038;utm_medium=rss&#038;utm_campaign=how-to-add-the-parent-category-class-to-body_class</link>
		<comments>http://www.tammyhartdesigns.com/wordpress/how-to-add-the-parent-category-class-to-body_class/#comments</comments>
		<pubDate>Wed, 16 Dec 2009 18:04:18 +0000</pubDate>
		<dc:creator>Tammy Hart</dc:creator>
				<category><![CDATA[Tutorials]]></category>
		<category><![CDATA[WordPress]]></category>

		<guid isPermaLink="false">http://tammyhartdesigns.com/?p=959</guid>
		<description><![CDATA[WordPress 2.8 came out with a bang, offering some great new functions for using in your templates. One of these is called body_class. It&#8217;s a simple function you include in the body tag that will automatically add a class to the body tag that is specific to the page you are on. For instance, if&#8230;]]></description>
			<content:encoded><![CDATA[<p>WordPress 2.8 came out with a bang, offering some great new functions for using in your templates. One of these is called body_class. It&#8217;s a simple function you include in the body tag that will automatically add a class to the body tag that is specific to the page you are on. For instance, if you are on a category page, it will add the class &#8220;category&#8221;. If you are on the home page, it adds the class &#8220;home&#8221;. It&#8217;s easy to implement, and looks like this:
<pre class="brush: php; title: ; notranslate">&lt;?php body_class(); ?&gt;&gt;</pre>
<p>There are a ton of articles out there already about this that deal with adding your own custom classes, one of the best being &#8220;><a href="http://www.nathanrice.net/blog/wordpress-2-8-and-the-body_class-function/" target="_blank">WordPress 2.8 and the body_class() Function</a>&#8220;, but I ran into a specific need for a project I&#8217;m working on, and wanted to share my solution, since it wasn&#8217;t something I had been able to find pre-written.</p>
<p>For this project, I was using the body class to add a specific color to a nav item whenever I was on an active page that fell under that nav item. It was simple to do for pages, but when I got to the pages that I use for custom category listings as discussed in &#8220;<a href="http://tammyhartdesigns.com/tutorials/wordpress-create-a-page-template-that-paginates-posts-from-a-certain-category/">WordPress: Create a Page Template that Paginates Posts from a Certain Category</a>&#8220;, I found out that on a single post, the body_class() function doesn&#8217;t add the categories, like it does in post_class(). Furthermore, when I did discover how to add the categories, it didn&#8217;t list the parent of that category, which is what I needed. This was the solution I was able to piece together, I hope you find it useful:</p>
<pre class="brush: php; title: ; notranslate">
&lt;?php $class=''; /* Make it void by default */

if ( is_single() || is_category() ) { /* Only do this if we're on a single post or category page */
	$category = get_the_category();
	$parent = $category[0]-&gt;category_parent;
	$class = get_cat_name($parent); /* assign the permalink name for the parent category to the object $class */
}?&gt;

&lt;body &lt;?php body_class($class); /* This will add our custom class, which is void if we aren't on a single post or category page */ ?&gt;&gt;
</pre>
]]></content:encoded>
			<wfw:commentRss>http://www.tammyhartdesigns.com/wordpress/how-to-add-the-parent-category-class-to-body_class/feed/</wfw:commentRss>
		<slash:comments>1</slash:comments>
		</item>
		<item>
		<title>WordPress: Create a Page Template that Paginates Posts from a Certain&#160;Category</title>
		<link>http://www.tammyhartdesigns.com/wordpress/wordpress-create-a-page-template-that-paginates-posts-from-a-certain-category/?utm_source=rss&#038;utm_medium=rss&#038;utm_campaign=wordpress-create-a-page-template-that-paginates-posts-from-a-certain-category</link>
		<comments>http://www.tammyhartdesigns.com/wordpress/wordpress-create-a-page-template-that-paginates-posts-from-a-certain-category/#comments</comments>
		<pubDate>Fri, 04 Sep 2009 15:07:06 +0000</pubDate>
		<dc:creator>Tammy Hart</dc:creator>
				<category><![CDATA[Tutorials]]></category>
		<category><![CDATA[WordPress]]></category>

		<guid isPermaLink="false">http://www.tammyhartdesigns.com/?p=644</guid>
		<description><![CDATA[Update! There is a much better method for accomplishing this. Just skim the comments on the post to see how many people have had issues with this outdated method. Learn more about creating custom category templates. One of the most important tools WordPress provides a custom theme developer is the simple ability to create custom page templates&#8230;]]></description>
			<content:encoded><![CDATA[<p class="note"><strong>Update!</strong> There is a much better method for accomplishing this. Just skim the comments on the post to see how many people have had issues with this outdated method. Learn more about creating <a href="http://www.tammyhartdesigns.com/wordpress/taking-advantage-of-the-template-hierarchy/">custom category templates</a>.</p>
<p><img class="alignright size-full wp-image-645" title="attributes" src="http://www.tammyhartdesigns.com/wp-content/uploads/2009/09/attributes.jpg" alt="attributes" width="250" /></p>
<p>One of the most important tools WordPress provides a custom theme developer is the simple ability to create custom page templates that can be used on particular pages to get specialized results apart from the basic static page template. For instance, <a href="http://www.tammyhartdesigns.com/">my homepage</a> is just another WordPress page, but in order to get it to look differently from <a href="http://www.tammyhartdesigns.com/about/wordpress-blogs-and-cms-solutions/">a regular page</a> and the <a href="http://www.tammyhartdesigns.com/blog/">main blog page</a>, I have created a template called &#8220;Homepage&#8221; and then in the Page attributes, I&#8217;ve selected the template for that page.</p>
<p>Another thing that I do a lot on custom pages is to query posts from a particular category. This especially came in handy for pages like <a href="http://www.tammyhartdesigns.com/portfolio/">my Portfolio</a>. One special thing to take note of is the fact that I don&#8217;t simply list all of the entries on one page, but instead break it up into sets by paginating the results of the query. This is simple to do, and I&#8217;m going to show you how.</p>
<h2>Create a Page Template</h2>
<p>First off, you&#8217;ll need to start with a custom template, and the easiest way to do that is duplicate your normal page template,<code> page.php</code>. In this file, add the following code above the call for the header:</p>
<pre class="brush: php; title: ; notranslate">&lt;?php
/*
Template Name: ANY NAME YOU WANT
*/
?&gt;</pre>
<p>Now you can add any customizations to it that you want and then assign that template to a page by selecting it from the &#8220;template&#8221; dropdown in the Attributes panel as is shown in the above image.</p>
<h2>Create a Custom Loop</h2>
<p>So now that we have our custom template, let&#8217;s put in the custom query that calls posts from the category with the ID of 3. This would typically look like this:</p>
<pre class="brush: php; title: ; notranslate">&lt;?php
$temp = $wp_query;
$wp_query= null;
$wp_query = new WP_Query();
$wp_query-&gt;query('cat=3');
?&gt;

&lt;?php while ($wp_query---&gt;have_posts()): $wp_query-&gt;the_post(); ?&gt;

... HTML and other post stuff here...

&lt;?php endwhile; ?&gt;

&lt;?php $wp_query = null; $wp_query = $temp; ?&gt;</pre>
<p>Now, we will add in a couple more variables to the query to tell it to display just 4 posts per page. Now you&#8217;re query looks like this:</p>
<pre class="brush: php; title: ; notranslate">&lt;?php
$temp = $wp_query;
$wp_query= null;
$wp_query = new WP_Query();
$wp_query-&gt;query('cat=3&amp;showposts=4'.'&amp;paged='.$paged);
?&gt;</pre>
<h2>Don&#8217;t forget Pagination</h2>
<p>Finally, you need to include the pagination links somewhere after the <code>&lt;?php endwhile;? &gt;</code>. If you are using the default navigation, that will look like this:</p>
<pre class="brush: php; title: ; notranslate">
&lt;div class=&quot;navigation&quot;&gt;
	&lt;div class=&quot;alignleft&quot;&gt;&lt;? next_posts_link('&amp;larr; Older Entries') ?&gt;&lt;/div&gt;
	&lt;div class=&quot;alignright&quot;&gt;&lt;? previous_posts_link('Newer Entries &amp;rarr;') ?&gt;&lt;/div&gt;
&lt;/div&gt;
</pre>
<p>If you&#8217;re like me, and you prefer to use the awesome plugin by <a href="http://lesterchan.net/portfolio/programming/php/">Lester Chan</a> called <a href="http://wordpress.org/extend/plugins/wp-pagenavi/">WP-PageNavi</a>, then that looks like this:</p>
<pre class="brush: php; title: ; notranslate">&lt;?php if(function_exists('wp_pagenavi')) { wp_pagenavi(); } ?&gt;</pre>
]]></content:encoded>
			<wfw:commentRss>http://www.tammyhartdesigns.com/wordpress/wordpress-create-a-page-template-that-paginates-posts-from-a-certain-category/feed/</wfw:commentRss>
		<slash:comments>42</slash:comments>
		</item>
		<item>
		<title>How to Use Categories as Your Navigation&#160;Bar</title>
		<link>http://www.tammyhartdesigns.com/wordpress/wordpress-how-to-use-categories-as-your-navigation-bar/?utm_source=rss&#038;utm_medium=rss&#038;utm_campaign=wordpress-how-to-use-categories-as-your-navigation-bar</link>
		<comments>http://www.tammyhartdesigns.com/wordpress/wordpress-how-to-use-categories-as-your-navigation-bar/#comments</comments>
		<pubDate>Sun, 19 Apr 2009 16:37:23 +0000</pubDate>
		<dc:creator>Tammy Hart</dc:creator>
				<category><![CDATA[Tutorials]]></category>
		<category><![CDATA[WordPress]]></category>

		<guid isPermaLink="false">http://www.tammyhartdesigns.com/?p=452</guid>
		<description><![CDATA[I wrote a post a few months back that discusses >how to use pages in a horizontal navigation bar. It&#8217;s a pretty standard thing to see a horizontal navigation, but a lot of blogs that don&#8217;t pull as much focus to their static pages are using their categories as their main navigation. If you&#8217;re wanting&#8230;]]></description>
			<content:encoded><![CDATA[<p>I wrote a post a few months back that discusses ><a href="http://www.tammyhartdesigns.com/tutorials/wordpress-how-to-use-pages-in-a-horizontal-navigation-bar/">how to use pages in a horizontal navigation bar</a>. It&#8217;s a pretty standard thing to see a horizontal navigation, but a lot of blogs that don&#8217;t pull as much focus to their static pages are using their categories as their main navigation. If you&#8217;re wanting to do this in a horizontal style, a good example is right above you on my own blog, where I use them as a secondary navigation.</p>
<p>You can pretty much follow all of the steps outlined in my <a href="http://www.tammyhartdesigns.com/tutorials/wordpress-how-to-use-pages-in-a-horizontal-navigation-bar/">previous article</a>, except rather than using <code>wp_list_pages</code>, you&#8217;ll want to use <code>wp_list_categories</code> like so:</p>
<pre class="brush: php; title: ; notranslate">&lt;ul id=&quot;nav&quot;&gt;
wp_list_categories('title_li=');
&lt;/ul&gt;</pre>
<p>As usual, make sure that you leave that <code>title_li=</code> in there without a value so that the code is rendered semantically.</p>
<p>The only problem you may run into is if you use child categories. This can be fixed by using a dropdown method such as <a href="http://htmldog.com/articles/suckerfish/dropdowns/">Suckerfish</a>. Changing the depth of the list that WordPress delivers is the same with categories as it is with pages, so adding the variable <code>depth=1</code> will eliminate the need for dropdowns since all you&#8217;ll get is the parent categories.</p>
]]></content:encoded>
			<wfw:commentRss>http://www.tammyhartdesigns.com/wordpress/wordpress-how-to-use-categories-as-your-navigation-bar/feed/</wfw:commentRss>
		<slash:comments>1</slash:comments>
		</item>
		<item>
		<title>Need Your Ideas for an Upcoming Tutorial&#160;Series</title>
		<link>http://www.tammyhartdesigns.com/tutorials/need-your-ideas-for-an-upcoming-tutorial-series/?utm_source=rss&#038;utm_medium=rss&#038;utm_campaign=need-your-ideas-for-an-upcoming-tutorial-series</link>
		<comments>http://www.tammyhartdesigns.com/tutorials/need-your-ideas-for-an-upcoming-tutorial-series/#comments</comments>
		<pubDate>Wed, 18 Mar 2009 21:56:32 +0000</pubDate>
		<dc:creator>Tammy Hart</dc:creator>
				<category><![CDATA[Tutorials]]></category>

		<guid isPermaLink="false">http://www.tammyhartdesigns.com/?p=425</guid>
		<description><![CDATA[I&#8217;m going to exercise my writing muscles a little bit as I begin to prepare a tutorial series that will cover how wordpress templating works. It will include explanations of basic functions and then give ideas for expounding on the basics a bit, including styling tips and examples. But I want to make sure I&#8230;]]></description>
			<content:encoded><![CDATA[<p>I&#8217;m going to exercise my writing muscles a little bit as I begin to prepare a tutorial series that will cover how wordpress templating works. It will include explanations of basic functions and then give ideas for expounding on the basics a bit, including styling tips and examples. But I want to make sure I cover all the bases, so please leave a comment here, or <a href="http://www.tammyhartdesigns.com/contact/">contact me</a> with your ideas and questions about anything you&#8217;d like to know or have explained.</p>
]]></content:encoded>
			<wfw:commentRss>http://www.tammyhartdesigns.com/tutorials/need-your-ideas-for-an-upcoming-tutorial-series/feed/</wfw:commentRss>
		<slash:comments>1</slash:comments>
		</item>
		<item>
		<title>WordPress: How to Determine if a Certain Page&#160;Exists</title>
		<link>http://www.tammyhartdesigns.com/wordpress/wordpress-how-to-determine-if-a-certain-page-exists/?utm_source=rss&#038;utm_medium=rss&#038;utm_campaign=wordpress-how-to-determine-if-a-certain-page-exists</link>
		<comments>http://www.tammyhartdesigns.com/wordpress/wordpress-how-to-determine-if-a-certain-page-exists/#comments</comments>
		<pubDate>Mon, 26 Jan 2009 02:23:06 +0000</pubDate>
		<dc:creator>Tammy Hart</dc:creator>
				<category><![CDATA[Tutorials]]></category>
		<category><![CDATA[WordPress]]></category>

		<guid isPermaLink="false">http://www.tammyhartdesigns.com/?p=374</guid>
		<description><![CDATA[I am developing a new premium theme called &#8220;Tidings&#8221; which will be a news theme unlike most I&#8217;ve seen available. One module on the front page will contain recent comments or &#8220;discussions&#8221;. I want to give the user the option of having an entire page for discussions (i.e. listing the most recent comments), and then&#8230;]]></description>
			<content:encoded><![CDATA[<p>I am developing a new premium theme called &#8220;Tidings&#8221; which will be a news theme unlike most I&#8217;ve seen available. One module on the front page will contain recent comments or &#8220;discussions&#8221;. I want to give the user the option of having an entire page for discussions (i.e. listing the most recent comments), and then provide a link to this page from the front page discussions module. But if they don&#8217;t choose to have that page, no link is necessary. So I set out to figure out how to test if a certain page named &#8220;discussions&#8221; exists. Combining a little knowledge I&#8217;ve gained from my experience in tweaking WordPress, and just my all around ingeniousness (one of those options is exaggerated, you can be the judge), I was able to come up with the following code. So use it, and enjoy it, and post back any questions you might have, or if you know a better way, then by all means, do share!</p>
<pre class="brush: php; title: ; notranslate">&lt;?php
$pages = get_pages();
foreach ($pages as $page) {
	$apage = $page-&gt;post_name;
	if ($apage == 'discussions') { ?&gt;
		&lt;a class=&quot;more&quot; href=&quot;&lt;?php bloginfo('home'); ?&gt;/discussions&quot;&gt;More&lt;/a&gt;
	&lt;?php }
} ?&gt;</pre>
]]></content:encoded>
			<wfw:commentRss>http://www.tammyhartdesigns.com/wordpress/wordpress-how-to-determine-if-a-certain-page-exists/feed/</wfw:commentRss>
		<slash:comments>10</slash:comments>
		</item>
		<item>
		<title>WordPress: How to Use Pages in a Horizontal Navigation&#160;bar</title>
		<link>http://www.tammyhartdesigns.com/wordpress/wordpress-how-to-use-pages-in-a-horizontal-navigation-bar/?utm_source=rss&#038;utm_medium=rss&#038;utm_campaign=wordpress-how-to-use-pages-in-a-horizontal-navigation-bar</link>
		<comments>http://www.tammyhartdesigns.com/wordpress/wordpress-how-to-use-pages-in-a-horizontal-navigation-bar/#comments</comments>
		<pubDate>Mon, 15 Dec 2008 16:45:55 +0000</pubDate>
		<dc:creator>Tammy Hart</dc:creator>
				<category><![CDATA[Tutorials]]></category>
		<category><![CDATA[WordPress]]></category>

		<guid isPermaLink="false">http://www.tammyhartdesigns.com/?p=315</guid>
		<description><![CDATA[One of the first things I do when I create a new WordPress Theme design, is to remove the page listing from the sidebar, and give it more prominence in a horizontal nav bar. Even if you use WordPress as a blog, putting your pages in the header area of the layout makes them stand&#8230;]]></description>
			<content:encoded><![CDATA[<p>One of the first things I do when I create a new WordPress Theme design, is to remove the page listing from the sidebar, and give it more prominence in a horizontal nav bar. Even if you use WordPress as a blog, putting your pages in the header area of the layout makes them stand out more as &#8220;look at me for more info&#8221; links, than the standard blog information does.</p>
<h2>Move the navigation to the header</h2>
<p>The first step is to open up your sidebar.php template and find this snippet of code:</p>
<pre class="brush: php; title: ; notranslate">
&lt;?php
wp_list_pages('title_li=&lt;h2&gt;Pages&lt;/h2&gt;');
?&gt;
</pre>
<p>Cut it out and then place it within your header.php where you&#8217;d like it to be. Most likely, you won&#8217;t be wanting the &#8220;pages&#8221; header, and you&#8217;ll also need to put it inside an unordered list with an id or class that you can use for styling it from within the css, so your code should now look like this:</p>
<pre class="brush: php; title: ; notranslate">
&lt;ul id=&quot;nav&quot;&gt;
	&lt;?php wp_list_pages('title_li='); ?&gt;
&lt;/ul&gt;
</pre>
<h2>Cause the pages to list horizontally</h2>
<p>Now open up your stylesheet (style.css) and begin styling the nav id. Most people will want their list items to float left so that you don&#8217;t lose the ability to use block item styling like borders and dimensions that you would if you just told them to display inline. Here is a good basic setup to get you started:</p>
<pre class="brush: css; title: ; notranslate">
ul#nav {
height:25px;
border:1px solid #ccc;
background:#eee;
margin:1em 0;
padding:0;
}

ul#nav li {
list-style:none;
float:left;
border-right:1px solid #ccc;
line-height:25px;
padding:0 10px;
}
</pre>
<p>Yay! Now your header includes a horizontal navigation bar.</p>
<h2>Taking the style to the next step</h2>
<p>Of course you have unlimited possibilities as to the appearance of your navigation bar. Depending on your design and styling capabilities you can really jazz up the look of a simple list of pages. Here are some great examples to give you some inspiration:</p>
<div id="attachment_320" class="wp-caption aligncenter" style="width: 510px"><a href="http://www.smashingmagazine.com"><img src="http://www.tammyhartdesigns.com/wp-content/uploads/2008/12/nav-smashing.jpg" alt="Smashing Magazine" title="nav-smashing" width="460" class="size-full wp-image-320" /></a><p class="wp-caption-text">Smashing Magazine</p></div>
<div id="attachment_322" class="wp-caption aligncenter" style="width: 510px"><a href="http://zenhabits.net/"><img src="http://www.tammyhartdesigns.com/wp-content/uploads/2008/12/nav-zen.jpg" alt="Zen Habits" title="nav-zen" width="500" height="80" class="size-full wp-image-322" /></a><p class="wp-caption-text">Zen Habits</p></div>
<div id="attachment_319" class="wp-caption aligncenter" style="width: 510px"><a href="http://www.wanderinggoat.com/"><img src="http://www.tammyhartdesigns.com/wp-content/uploads/2008/12/nav-goat.jpg" alt="Wandering Goat" title="nav-goat" width="500" height="80" class="size-full wp-image-319" /></a><p class="wp-caption-text">Wandering Goat</p></div>
<div id="attachment_318" class="wp-caption aligncenter" style="width: 510px"><a href="http://www.tammyhartdesigns.com/portfolio/comag-marketing-group/"><img src="http://www.tammyhartdesigns.com/wp-content/uploads/2008/12/nav-cmg.jpg" alt="Comag Marketing Group" title="nav-cmg" width="500" height="80" class="size-full wp-image-318" /></a><p class="wp-caption-text">Comag Marketing Group</p></div>
<h2>Child Pages</h2>
<p>If you use a lot of child pages on your blog, you are probably seeing a few errors. There are two solutions for this. One, is using <a href="http://htmldog.com/articles/suckerfish/dropdowns/">suckerfish dropdowns</a>, and the other is <a href="http://www.tammyhartdesigns.com/tutorials/wordpress-how-to-list-child-pages-in-sidebar/">listing the child pages in the sidebar</a> only when you&#8217;ve chosen a particular parent page.</p>
<p>If you do use my sidebar solution, be sure to exclude showing them in the header.php template by adding an additional parameter to your code like this:</p>
<pre class="brush: php; title: ; notranslate">
&lt;ul id=&quot;nav&quot;&gt;
	&lt;?php wp_list_pages('depth=1&amp;title_li='); ?&gt;
&lt;/ul&gt;
</pre>
<p>If all of this seems too much for you, or you just want a quicker way to get to the designing, then you might enjoy using my <a href="http://www.tammyhartdesigns.com/resources/free-wordpress-theme-imageless/">imageless theme</a> as a basis for your customization.</p>
]]></content:encoded>
			<wfw:commentRss>http://www.tammyhartdesigns.com/wordpress/wordpress-how-to-use-pages-in-a-horizontal-navigation-bar/feed/</wfw:commentRss>
		<slash:comments>28</slash:comments>
		</item>
	</channel>
</rss>

