<?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>Dru Darby</title>
	<atom:link href="http://drudarby.com/feed/" rel="self" type="application/rss+xml" />
	<link>http://drudarby.com</link>
	<description>Just another WordPress site</description>
	<lastBuildDate>Wed, 17 Nov 2010 19:50:50 +0000</lastBuildDate>
	<language>en</language>
	<sy:updatePeriod>hourly</sy:updatePeriod>
	<sy:updateFrequency>1</sy:updateFrequency>
	<generator>http://wordpress.org/?v=3.2.1</generator>
		<item>
		<title>My new website design</title>
		<link>http://drudarby.com/2010/11/my-new-website-design/</link>
		<comments>http://drudarby.com/2010/11/my-new-website-design/#comments</comments>
		<pubDate>Wed, 17 Nov 2010 19:47:20 +0000</pubDate>
		<dc:creator>drumichael87</dc:creator>
				<category><![CDATA[Announcement]]></category>
		<category><![CDATA[Featured]]></category>

		<guid isPermaLink="false">http://drudarby.com/?p=51</guid>
		<description><![CDATA[Well, I've been working on my new design for a few weeks now, and I finally feel that it is ready enough to go live with.  I'd really like to know what you think about it, so use the comments area below to let me know.

If you know me, you know that I like to use as many cool features in a website as possible.  I don't have everything just the way I want it right now, but it only gets better from here!  I'm really excited about my soon-to-come archives page, as well as an awesome new sidebar layout.]]></description>
			<content:encoded><![CDATA[<p>Well, I&#8217;ve been working on my new design for a few weeks now, and I finally feel that it is ready enough to go live with.  I&#8217;d really like to know what you think about it, so use the comments area below to let me know.</p>
<p>If you know me, you know that I like to use as many cool features in a website as possible.  I don&#8217;t have everything just the way I want it right now, but it only gets better from here!  I&#8217;m really excited about my soon-to-come archives page, as well as an awesome new sidebar layout.</p>
<p>Follow me on twitter @drudarby, or facebook @drumichael87 to keep up to date on my new site.</p>
<p>Some of the new things I&#8217;ve done that I really like are:</p>
<ul>
<li>The new logo is my own handwritten signature</li>
<li>Nifty Description text on the navigation items on hover</li>
<li>Blog post rating system</li>
<li>Official portfolio page</li>
<li>Using TimThumb for post images &#8211; however I plant to try out the native Featured Image feature soon</li>
</ul>
<p>These are just a few of the things that I plan to implement in the site, and there&#8217;s more to come!</p>
<div class="shr-publisher-51"></div>]]></content:encoded>
			<wfw:commentRss>http://drudarby.com/2010/11/my-new-website-design/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>Page title images</title>
		<link>http://drudarby.com/2010/11/page-title-images/</link>
		<comments>http://drudarby.com/2010/11/page-title-images/#comments</comments>
		<pubDate>Wed, 17 Nov 2010 11:03:25 +0000</pubDate>
		<dc:creator>drumichael87</dc:creator>
				<category><![CDATA[Tutorials]]></category>
		<category><![CDATA[Wordpress]]></category>

		<guid isPermaLink="false">http://drudarby.com/?p=42</guid>
		<description><![CDATA[Using images on your posts and pages is a great way to better the user experience on your website or blog.  It separates your posts and pages from each other, and breaks the monotony of text, text and more text.
I've been asked a few times whether or not I used some "special method" of getting a different image beside the title of each of my pages here on my website.  Remember that there are a few different ways of doing this, however since I only have 4 main pages on my website, this method worked pretty good for me.  I don't think it is really a "special method", but here's what I did.]]></description>
			<content:encoded><![CDATA[<p>Using images on your posts and pages is a great way to better the user experience on your website or blog.  It separates your posts and pages from each other, and breaks the monotony of text, text and more text.<br />
I&#8217;ve been asked a few times whether or not I used some &#8220;special method&#8221; of getting a different image beside the title of each of my pages here on my website.  Remember that there are a few different ways of doing this, however since I only have 4 main pages on my website, this method worked pretty good for me.  I don&#8217;t think it is really a &#8220;special method&#8221;, but here&#8217;s what I did.</p>
<p>Go ahead and collect the images that you want to use for your pages, and have them uploaded to your template directory.  I like to keep the naming method easy, so my images are named &#8220;contact_img.png&#8221;, &#8220;portfolio_img.png&#8221;, etc.  Also, to keep the images on the pages consistent, make sure they are all the same size.  My images are all 64&#215;64.</p>
<p>We are going to set the image as the background of the div holding our title, as well as make the size of the text larger for pages than it is for posts.  The way to identify a div in a stylesheet is by assigning it a &#8220;class&#8221;.  The class that we give the div on our POSTS looks like this:</p>
<pre class="brush: php">
&lt;div class=&quot;title&quot;&gt;
   &lt;?php the_title(); ?&gt;
&lt;/div&gt;
</pre>
<p>The class can always be the same (title) for our POSTS because we aren&#8217;t going have dynamic styles for each post.  For our PAGES, however, we want to have a class that is different for each page, without having to create a template file in our theme for each page.<br />
We want to change two things about our title div&#8217;s: font-size and background-image.  Font-size will be the same for each page, and background-image will be different for each page, so we can use two classes on the one div.</p>
<pre class="brush: php">
&lt;div class=&quot;&lt;?php if ( is_page() ) {
 echo &quot;page_title&quot;;
 } else {
 echo &quot;title&quot;;
 } ?&gt; &lt;?php the_title(); ?&gt;&quot;&gt;
 </pre>
<p>What you see here is a dynamically created class.  First, WordPress checks to see if what we are looking at is a page, and if it is, it prints (echos) &#8220;page_title&#8221;.  If it&#8217;s not, it simply prints &#8220;title&#8221; which is what we want for our posts.  Then there&#8217;s a space, and finally the title.  When we view source of a page, we see this for the Portfolio page: </p>
<pre class="brush: php">
&lt;div class=&quot;page_title Portfolio&quot;&gt;
Portfolio
&lt;/div&gt;
</pre>
<p>Now, in our CSS, we can style the image background as well as the size and indent of the text:</p>
<pre class="brush: php">
.page_title {font-size: 6em; text-indent: 68px; }
.Portfolio {background: url(images/portfolio_img.png) no-repeat; }
</pre>
<p>Notice we had to use text-indent to move the text to the right to be out of the way of the background image we are using.  The images I used are all 64px, so giving a 68px indent gives us room for the image, plus a little padding. </p>
<p>I hope this tutorial has been helpful.  Let me see how you&#8217;ve implemented it!</p>
<div class="shr-publisher-42"></div>]]></content:encoded>
			<wfw:commentRss>http://drudarby.com/2010/11/page-title-images/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
	</channel>
</rss>

