<?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>Jared Heinrichs &#187; CSS</title>
	<atom:link href="http://jaredheinrichs.com/category/programming/css/feed" rel="self" type="application/rss+xml" />
	<link>http://jaredheinrichs.com</link>
	<description>A Winnipeg &#34;How to&#34; Blog on Software and Technology</description>
	<lastBuildDate>Sat, 19 May 2012 22:43:26 +0000</lastBuildDate>
	<language>en</language>
	<sy:updatePeriod>hourly</sy:updatePeriod>
	<sy:updateFrequency>1</sy:updateFrequency>
			<item>
		<title>CSS Relative image URL</title>
		<link>http://jaredheinrichs.com/css-relative-image-url.html</link>
		<comments>http://jaredheinrichs.com/css-relative-image-url.html#comments</comments>
		<pubDate>Tue, 31 Jan 2012 20:27:37 +0000</pubDate>
		<dc:creator>Jared Heinrichs</dc:creator>
				<category><![CDATA[CSS]]></category>

		<guid isPermaLink="false">http://jaredheinrichs.com/?p=4701</guid>
		<description><![CDATA[When using relative URLS, CSS images are always relative to the CSS FILE and NOT the Page URL! Take this bit of CSS: Make sure that you create a folder in the folder where the CSS file is located. Call &#8230; <a href="http://jaredheinrichs.com/css-relative-image-url.html">Continue reading <span class="meta-nav">&#8594;</span></a>]]></description>
			<content:encoded><![CDATA[<p>When using relative URLS, <strong>CSS images are always relative to the CSS FILE and NOT the Page URL</strong>!</p>
<p>Take this bit of CSS:</p>
<p><a href="http://jaredheinrichs.com/wp-content/uploads/2012/01/image4.png"><img style="border-bottom: 0px; border-left: 0px; display: inline; border-top: 0px; border-right: 0px" title="image" border="0" alt="image" src="http://jaredheinrichs.com/wp-content/uploads/2012/01/image_thumb.png" width="372" height="45" /></a> </p>
<ul>
<li>Make sure that you create a folder in the folder where the CSS file is located. Call it images.</li>
<li>Create a new file inside of images and called it: “header-background.jpg”</li>
</ul>
<p>If you make the CSS relative to the page you will be in a world of hurt!</p>
]]></content:encoded>
			<wfw:commentRss>http://jaredheinrichs.com/css-relative-image-url.html/feed</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>A running collection of fonts I like on Websites</title>
		<link>http://jaredheinrichs.com/a-running-collection-of-fonts-i-like-on-websites.html</link>
		<comments>http://jaredheinrichs.com/a-running-collection-of-fonts-i-like-on-websites.html#comments</comments>
		<pubDate>Wed, 27 Apr 2011 18:02:19 +0000</pubDate>
		<dc:creator>Jared Heinrichs</dc:creator>
				<category><![CDATA[CSS]]></category>

		<guid isPermaLink="false">http://jaredheinrichs.com/a-running-collection-of-fonts-i-like-on-websites.html</guid>
		<description><![CDATA[Headings Page Example: Code Example: copy and paste: font-family: &#34;Yanone Kaffeesatz&#34;,&#34;Arial Narrow&#34;,Arial,sans-serif;]]></description>
			<content:encoded><![CDATA[<h2>Headings</h2>
<h3>Page Example: </h3>
<p><img style="background-image: none; border-bottom: 0px; border-left: 0px; margin: 0px; padding-left: 0px; padding-right: 0px; display: inline; border-top: 0px; border-right: 0px; padding-top: 0px" title="image" border="0" alt="image" src="http://jaredheinrichs.com/wp-content/uploads/2011/04/image6.png" width="526" height="42" /></p>
<h3>Code Example:</h3>
<p><img style="background-image: none; border-bottom: 0px; border-left: 0px; padding-left: 0px; padding-right: 0px; display: inline; border-top: 0px; border-right: 0px; padding-top: 0px" title="image" border="0" alt="image" src="http://jaredheinrichs.com/wp-content/uploads/2011/04/image7.png" width="466" height="126" /></p>
<h3>copy and paste:</h3>
<p>font-family: &quot;Yanone Kaffeesatz&quot;,&quot;Arial Narrow&quot;,Arial,sans-serif;</p>
]]></content:encoded>
			<wfw:commentRss>http://jaredheinrichs.com/a-running-collection-of-fonts-i-like-on-websites.html/feed</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>z-index background issues</title>
		<link>http://jaredheinrichs.com/z-index-background-issues.html</link>
		<comments>http://jaredheinrichs.com/z-index-background-issues.html#comments</comments>
		<pubDate>Mon, 13 Dec 2010 17:45:21 +0000</pubDate>
		<dc:creator>Jared Heinrichs</dc:creator>
				<category><![CDATA[CSS]]></category>

		<guid isPermaLink="false">http://jaredheinrichs.com/z-index-background-issues.html</guid>
		<description><![CDATA[This post will cover how I worked around some z-index background issues I was having. In a recent project I was working on I wanted to use a “div” underneath a bunch of list items/anchor tags. I wanted to see &#8230; <a href="http://jaredheinrichs.com/z-index-background-issues.html">Continue reading <span class="meta-nav">&#8594;</span></a>]]></description>
			<content:encoded><![CDATA[<p>This post will cover how I worked around some z-index background issues I was having. In a recent project I was working on I wanted to use a “div” underneath a bunch of list items/anchor tags. I wanted to see the “div” above the rest of the items but below List items. While it’s pretty trivial doing it if NON of the items in the DOM tree have a background applied to them, I needed to use a background color.</p>
<p>*NOTE* &#8211; Before I go any further you might be asking why I didn’t just us a background color using CSS for each item. I couldn’t use the easy way because I eventually I wanted to slide the “highlight” from the left to where ever the person was holding their mouse.</p>
<p>Here’s an example of what I wanted to make:</p>
<p><a href="http://jaredheinrichs.com/wp-content/uploads/2010/12/image7.png"><img style="background-image: none; border-bottom: 0px; border-left: 0px; margin: 0px; padding-left: 0px; padding-right: 0px; display: inline; border-top: 0px; border-right: 0px; padding-top: 0px" title="image" border="0" alt="image" src="http://jaredheinrichs.com/wp-content/uploads/2010/12/image_thumb.png" width="384" height="94" /></a></p>
<p>Unfortunately I kept getting something like this:</p>
<p><a href="http://jaredheinrichs.com/wp-content/uploads/2010/12/image8.png"><img style="background-image: none; border-bottom: 0px; border-left: 0px; margin: 0px; padding-left: 0px; padding-right: 0px; display: inline; border-top: 0px; border-right: 0px; padding-top: 0px" title="image" border="0" alt="image" src="http://jaredheinrichs.com/wp-content/uploads/2010/12/image_thumb1.png" width="371" height="92" /></a></p>
<p>Let’s look at the code to see how this issue can be resolved quite simply.</p>
<h2>XHTML</h2>
<p><a href="http://jaredheinrichs.com/wp-content/uploads/2010/12/image9.png"><img style="background-image: none; border-bottom: 0px; border-left: 0px; padding-left: 0px; padding-right: 0px; display: inline; border-top: 0px; border-right: 0px; padding-top: 0px" title="z-index background issue 01" border="0" alt="z-index background issue 01" src="http://jaredheinrichs.com/wp-content/uploads/2010/12/image_thumb2.png" width="500" height="410" /></a></p>
<h2>CSS (That didn’t work)</h2>
<p><a href="http://jaredheinrichs.com/wp-content/uploads/2010/12/image10.png"><img style="background-image: none; border-bottom: 0px; border-left: 0px; padding-left: 0px; padding-right: 0px; display: inline; border-top: 0px; border-right: 0px; padding-top: 0px" title="z-index background issue 02" border="0" alt="z-index background issue 02" src="http://jaredheinrichs.com/wp-content/uploads/2010/12/image_thumb3.png" width="336" height="545" /></a></p>
<h2>CSS (That did work. I’ve highlighted the line that fixed the issue) </h2>
<p><a href="http://jaredheinrichs.com/wp-content/uploads/2010/12/image11.png"><img style="background-image: none; border-bottom: 0px; border-left: 0px; padding-left: 0px; padding-right: 0px; display: inline; border-top: 0px; border-right: 0px; padding-top: 0px" title="z-index background issue 03" border="0" alt="z-index background issue 03" src="http://jaredheinrichs.com/wp-content/uploads/2010/12/image_thumb4.png" width="326" height="562" /></a></p>
<p>So basically I always thought the z-index on HTML elements was “0”/Or not set. This doesn’t seem to be the case. It looks like they are always set to 1. Another really important thing to include is the “position: relative”. If you were to excluded that from the code it wouldn’t work either.</p>
]]></content:encoded>
			<wfw:commentRss>http://jaredheinrichs.com/z-index-background-issues.html/feed</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>How to give an anchor tag a width and height</title>
		<link>http://jaredheinrichs.com/how-to-give-an-anchor-tag-a-width-and-height.html</link>
		<comments>http://jaredheinrichs.com/how-to-give-an-anchor-tag-a-width-and-height.html#comments</comments>
		<pubDate>Sat, 02 Oct 2010 14:09:24 +0000</pubDate>
		<dc:creator>Jared Heinrichs</dc:creator>
				<category><![CDATA[CSS]]></category>
		<category><![CDATA[How To]]></category>

		<guid isPermaLink="false">http://jaredheinrichs.com/how-to-give-an-anchor-tag-a-width-and-height.html</guid>
		<description><![CDATA[I’ve seen this happen a few times by junior web designers. They create a bunch of anchor tags and using CSS they give it a background color, width and height. Then they go refresh their web browser and voila. Only &#8230; <a href="http://jaredheinrichs.com/how-to-give-an-anchor-tag-a-width-and-height.html">Continue reading <span class="meta-nav">&#8594;</span></a>]]></description>
			<content:encoded><![CDATA[<p>I’ve seen this happen a few times by junior web designers. They create a bunch of anchor tags and using CSS they give it a background color, width and height. Then they go refresh their web browser and voila. Only the background color shows. </p>
<p>The width and height doesn’t seem to take. What they were wanting to get is to look something like this:</p>
<p><a href="http://jaredheinrichs.com/wp-content/uploads/2010/10/image.png"><img style="background-image: none; border-bottom: 0px; border-left: 0px; margin: 0px; padding-left: 0px; padding-right: 0px; display: inline; border-top: 0px; border-right: 0px; padding-top: 0px" title="image" border="0" alt="image" src="http://jaredheinrichs.com/wp-content/uploads/2010/10/image_thumb.png" width="307" height="157" /></a></p>
<p>Here’s&#160; an example with code of what I am talking about:</p>
<h3>HTML Code</h3>
<p><a href="http://jaredheinrichs.com/wp-content/uploads/2010/10/image1.png"><img style="background-image: none; border-bottom: 0px; border-left: 0px; margin: 0px; padding-left: 0px; padding-right: 0px; display: inline; border-top: 0px; border-right: 0px; padding-top: 0px" title="image" border="0" alt="image" src="http://jaredheinrichs.com/wp-content/uploads/2010/10/image_thumb1.png" width="357" height="86" /></a></p>
<h3>CSS Code</h3>
<p><a href="http://jaredheinrichs.com/wp-content/uploads/2010/10/image2.png"><img style="background-image: none; border-bottom: 0px; border-left: 0px; margin: 0px; padding-left: 0px; padding-right: 0px; display: inline; border-top: 0px; border-right: 0px; padding-top: 0px" title="image" border="0" alt="image" src="http://jaredheinrichs.com/wp-content/uploads/2010/10/image_thumb2.png" width="423" height="161" /></a></p>
<h3>Result</h3>
<p><a href="http://jaredheinrichs.com/wp-content/uploads/2010/10/image3.png"><img style="background-image: none; border-bottom: 0px; border-left: 0px; margin: 0px; padding-left: 0px; padding-right: 0px; display: inline; border-top: 0px; border-right: 0px; padding-top: 0px" title="image" border="0" alt="image" src="http://jaredheinrichs.com/wp-content/uploads/2010/10/image_thumb3.png" width="210" height="43" /></a></p>
<p>So why does this happen? This happens because anchor tags are not block level HTML elements but rather inline elements. So what is the difference between the two? Here is the definition of the two items:</p>
<p>Inline Element definition:</p>
<ul>
<li>Inline elements typically may only contain text and other inline elements. When rendered visually, inline elements do not usually begin on a new line. I found a good link that lists all of <a href="http://htmlhelp.com/reference/html40/inline.html" target="_blank">HTML inline elements</a>.</li>
</ul>
<p>Block Element:</p>
<ul>
<li>Block-level elements typically contain inline elements and other block-level elements. When rendered visually, block-level elements usually begin on a new line. I found a good link that lists all of the <a href="http://htmlhelp.com/reference/html40/block.html" target="_blank">HTML Block Elements</a>.</li>
</ul>
<p>So how would we get the anchor tags to show their widths and heights? Well we only would have to add one line of CSS code in the /* Buttons */ section. This is what the CSS would look like after we were done with it.</p>
<h3>CSS Code</h3>
<p><a href="http://jaredheinrichs.com/wp-content/uploads/2010/10/image4.png"><img style="background-image: none; border-bottom: 0px; border-left: 0px; margin: 0px; padding-left: 0px; padding-right: 0px; display: inline; border-top: 0px; border-right: 0px; padding-top: 0px" title="image" border="0" alt="image" src="http://jaredheinrichs.com/wp-content/uploads/2010/10/image_thumb4.png" width="404" height="155" /></a></p>
<p>After you have done this the buttons would now show their height and width. They would also be stacked on top of each other since the definition of a block element is to begin on a new line. If you didn’t want the buttons to be on new lines you could always float them to the left and put a padding on them.</p>
<p>I hope that helps explains thing a bit</p>
]]></content:encoded>
			<wfw:commentRss>http://jaredheinrichs.com/how-to-give-an-anchor-tag-a-width-and-height.html/feed</wfw:commentRss>
		<slash:comments>8</slash:comments>
		</item>
		<item>
		<title>Why CSS code margin:0px auto doesn&#8217;t center container</title>
		<link>http://jaredheinrichs.com/why-css-code-margin0px-auto-doesnt-center-container.html</link>
		<comments>http://jaredheinrichs.com/why-css-code-margin0px-auto-doesnt-center-container.html#comments</comments>
		<pubDate>Fri, 23 Apr 2010 04:29:15 +0000</pubDate>
		<dc:creator>Jared Heinrichs</dc:creator>
				<category><![CDATA[CSS]]></category>
		<category><![CDATA[How To]]></category>

		<guid isPermaLink="false">http://jaredheinrichs.com/why-css-code-margin0px-auto-doesnt-center-container.html</guid>
		<description><![CDATA[You may have come across this CSS annoyance. You go to type this in an HTML file: &#60;div class=&#34;mainWrapper&#34;&#62; &#60;p&#62;Test&#60;/p&#62; &#60;/div&#62; &#160; In your linked CSS file you type: .mainWrapper { width:1000; margin:0px auto; } &#160; You THINK… Ok. Top &#8230; <a href="http://jaredheinrichs.com/why-css-code-margin0px-auto-doesnt-center-container.html">Continue reading <span class="meta-nav">&#8594;</span></a>]]></description>
			<content:encoded><![CDATA[<p>You may have come across this CSS annoyance. You go to type this in an HTML file:</p>
<pre style="border-bottom: #cecece 1px solid; border-left: #cecece 1px solid; padding-bottom: 5px; background-color: #fbfbfb; min-height: 40px; padding-left: 5px; width: 347px; padding-right: 5px; height: 94px; overflow: auto; border-top: #cecece 1px solid; border-right: #cecece 1px solid; padding-top: 5px">
<pre style="background-color: #fbfbfb; margin: 0em; width: 100%; font-family: consolas,&#39;Courier New&#39;,courier,monospace; font-size: 12px"><span style="color: #0000ff">&lt;</span><span style="color: #800000">div</span> <span style="color: #ff0000">class</span>=<span style="color: #0000ff">&quot;mainWrapper&quot;</span><span style="color: #0000ff">&gt;</span>
</pre>
<pre style="background-color: #fbfbfb; margin: 0em; width: 100%; font-family: consolas,&#39;Courier New&#39;,courier,monospace; font-size: 12px">   <span style="color: #0000ff">&lt;</span><span style="color: #800000">p</span><span style="color: #0000ff">&gt;</span>Test<span style="color: #0000ff">&lt;/</span><span style="color: #800000">p</span><span style="color: #0000ff">&gt;</span>
</pre>
<pre style="background-color: #fbfbfb; margin: 0em; width: 100%; font-family: consolas,&#39;Courier New&#39;,courier,monospace; font-size: 12px"><span style="color: #0000ff">&lt;/</span><span style="color: #800000">div</span><span style="color: #0000ff">&gt;</span></pre>
</pre>
<p>&#160;</p>
<p>In your linked CSS file you type:</p>
<pre style="border-bottom: #cecece 1px solid; border-left: #cecece 1px solid; padding-bottom: 5px; background-color: #fbfbfb; min-height: 40px; padding-left: 5px; width: 344px; padding-right: 5px; height: 52px; overflow: auto; border-top: #cecece 1px solid; border-right: #cecece 1px solid; padding-top: 5px">
<pre style="background-color: #fbfbfb; margin: 0em; width: 100%; font-family: consolas,&#39;Courier New&#39;,courier,monospace; font-size: 12px">.<span style="color: #800000">mainWrapper</span> { <span style="color: #ff0000">width</span>:<span style="color: #0000ff">1000</span>; <span style="color: #ff0000">margin</span>:<span style="color: #0000ff">0px auto</span>; }</pre>
</pre>
<p>&#160;</p>
<p>You THINK… Ok. Top and Bottom margin is 0px. Ok. There is nothing above or below the box. Left and Right margins set to auto. Ok. Say your screen resolution is 1680px. We can see 1000px is used for mainWrapper. The rest should be used in the Margin. 680px divided by 2 equals 340px on either side.</p>
<p>If you think this way you are mostly correct. Unfortunately this doesn’t work all by itself. mainWrapper needs help from the container above it. (Most likely the &lt;body&gt; tag).</p>
<p>In order for mainWrapper object to float it needs this CSS code:</p>
<pre style="border-bottom: #cecece 1px solid; border-left: #cecece 1px solid; padding-bottom: 5px; background-color: #fbfbfb; min-height: 40px; padding-left: 5px; width: 235px; padding-right: 5px; height: 21px; overflow: auto; border-top: #cecece 1px solid; border-right: #cecece 1px solid; padding-top: 5px">
<pre style="background-color: #fbfbfb; margin: 0em; width: 100%; font-family: consolas,&#39;Courier New&#39;,courier,monospace; font-size: 12px">body { text-align:center; }</pre>
</pre>
<p>&#160;</p>
<p>Without this “text-align”, the box will not float in the middle of the screen. Without the “margin:0px auto; the box will not float either. You NEED both! Now go back to coding <img src='http://jaredheinrichs.com/wp-includes/images/smilies/icon_wink.gif' alt=';)' class='wp-smiley' /> </p>
]]></content:encoded>
			<wfw:commentRss>http://jaredheinrichs.com/why-css-code-margin0px-auto-doesnt-center-container.html/feed</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>Visual tutorial on the &#8220;clear&#8221; property</title>
		<link>http://jaredheinrichs.com/visual-tutorial-on-the-clear-property.html</link>
		<comments>http://jaredheinrichs.com/visual-tutorial-on-the-clear-property.html#comments</comments>
		<pubDate>Tue, 23 Mar 2010 19:23:39 +0000</pubDate>
		<dc:creator>Jared Heinrichs</dc:creator>
				<category><![CDATA[CSS]]></category>
		<category><![CDATA[How To]]></category>

		<guid isPermaLink="false">http://jaredheinrichs.com/visual-tutorial-on-the-clear-property.html</guid>
		<description><![CDATA[Today I will be giving a tutorial on the clear property and how it works. I am guessing this info at some point will help you troubleshoot your code as I am sure most people run into this every so &#8230; <a href="http://jaredheinrichs.com/visual-tutorial-on-the-clear-property.html">Continue reading <span class="meta-nav">&#8594;</span></a>]]></description>
			<content:encoded><![CDATA[<p>Today I will be giving a tutorial on the clear property and how it works. I am guessing this info at some point will help you troubleshoot your code as I am sure most people run into this every so often. I’m first just going to show you the code and right after I will explain what each one does. I will also get you to change a few things to show you how the clear property works.</p>
<p>Let’s first look at the HTML code for the file “clear.html”.</p>
<pre style="background-color: #fbfbfb; min-height: 40px; width: 589px; height: 215px; overflow: auto; border: #cecece 1px solid; padding: 5px;">
<pre style="background-color: #fbfbfb; margin: 0em; width: 100%; font-family: consolas,'Courier New',courier,monospace; font-size: 11px;"><span style="color: #0000ff;">&lt;</span>!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 strict//EN"<span style="color: #0000ff;">&gt;</span></pre>
<pre style="background-color: #fbfbfb; margin: 0em; width: 100%; font-family: consolas,'Courier New',courier,monospace; font-size: 11px;"><span style="color: #0000ff;">&lt;</span><span style="color: #800000;">html</span><span style="color: #0000ff;">&gt;</span></pre>
<pre style="background-color: #fbfbfb; margin: 0em; width: 100%; font-family: consolas,'Courier New',courier,monospace; font-size: 11px;">  <span style="color: #0000ff;">&lt;</span><span style="color: #800000;">head</span><span style="color: #0000ff;">&gt;</span></pre>
<pre style="background-color: #fbfbfb; margin: 0em; width: 100%; font-family: consolas,'Courier New',courier,monospace; font-size: 11px;">    <span style="color: #0000ff;">&lt;</span><span style="color: #800000;">title</span><span style="color: #0000ff;">&gt;</span>CSS Clear Property Tutorial<span style="color: #0000ff;">&lt;/</span><span style="color: #800000;">title</span><span style="color: #0000ff;">&gt;</span></pre>
<pre style="background-color: #fbfbfb; margin: 0em; width: 100%; font-family: consolas,'Courier New',courier,monospace; font-size: 11px;">    <span style="color: #0000ff;">&lt;</span><span style="color: #800000;">link</span> <span style="color: #ff0000;">rel</span>=<span style="color: #0000ff;">"stylesheet"</span> <span style="color: #ff0000;">href</span>=<span style="color: #0000ff;">"css/reset.css"</span><span style="color: #0000ff;">&gt;</span></pre>
<pre style="background-color: #fbfbfb; margin: 0em; width: 100%; font-family: consolas,'Courier New',courier,monospace; font-size: 11px;">    <span style="color: #0000ff;">&lt;</span><span style="color: #800000;">link</span> <span style="color: #ff0000;">rel</span>=<span style="color: #0000ff;">"stylesheet"</span> <span style="color: #ff0000;">href</span>=<span style="color: #0000ff;">"css/property.css"</span><span style="color: #0000ff;">&gt;</span></pre>
<pre style="background-color: #fbfbfb; margin: 0em; width: 100%; font-family: consolas,'Courier New',courier,monospace; font-size: 11px;">  <span style="color: #0000ff;">&lt;/</span><span style="color: #800000;">head</span><span style="color: #0000ff;">&gt;</span></pre>
<pre style="background-color: #fbfbfb; margin: 0em; width: 100%; font-family: consolas,'Courier New',courier,monospace; font-size: 11px;">  <span style="color: #0000ff;">&lt;</span><span style="color: #800000;">body</span><span style="color: #0000ff;">&gt;</span></pre>
<pre style="background-color: #fbfbfb; margin: 0em; width: 100%; font-family: consolas,'Courier New',courier,monospace; font-size: 11px;">      <span style="color: #0000ff;">&lt;</span><span style="color: #800000;">div</span> <span style="color: #ff0000;">id</span>=<span style="color: #0000ff;">"main-wrapper"</span> <span style="color: #ff0000;">class</span>=<span style="color: #0000ff;">"container"</span><span style="color: #0000ff;">&gt;</span></pre>
<pre style="background-color: #fbfbfb; margin: 0em; width: 100%; font-family: consolas,'Courier New',courier,monospace; font-size: 11px;">      <span style="color: #0000ff;">&lt;</span><span style="color: #800000;">div</span> <span style="color: #ff0000;">id</span>=<span style="color: #0000ff;">"header"</span><span style="color: #0000ff;">&gt;</span></pre>
<pre style="background-color: #fbfbfb; margin: 0em; width: 100%; font-family: consolas,'Courier New',courier,monospace; font-size: 11px;">          <span style="color: #0000ff;">&lt;</span><span style="color: #800000;">h1</span> <span style="color: #ff0000;">class</span>=<span style="color: #0000ff;">"red"</span><span style="color: #0000ff;">&gt;</span>H1 Tag<span style="color: #0000ff;">&lt;/</span><span style="color: #800000;">h1</span><span style="color: #0000ff;">&gt;</span></pre>
<pre style="background-color: #fbfbfb; margin: 0em; width: 100%; font-family: consolas,'Courier New',courier,monospace; font-size: 11px;">          <span style="color: #0000ff;">&lt;</span><span style="color: #800000;">p</span> <span style="color: #ff0000;">class</span>=<span style="color: #0000ff;">"bold red"</span><span style="color: #0000ff;">&gt;</span>Hello World<span style="color: #0000ff;">&lt;/</span><span style="color: #800000;">p</span><span style="color: #0000ff;">&gt;</span></pre>
<pre style="background-color: #fbfbfb; margin: 0em; width: 100%; font-family: consolas,'Courier New',courier,monospace; font-size: 11px;">      <span style="color: #0000ff;">&lt;/</span><span style="color: #800000;">div</span><span style="color: #0000ff;">&gt;</span></pre>
<pre style="background-color: #fbfbfb; margin: 0em; width: 100%; font-family: consolas,'Courier New',courier,monospace; font-size: 11px;">      <span style="color: #0000ff;">&lt;</span><span style="color: #800000;">div</span> <span style="color: #ff0000;">id</span>=<span style="color: #0000ff;">"main-content"</span> <span style="color: #ff0000;">class</span>=<span style="color: #0000ff;">"floatleft"</span><span style="color: #0000ff;">&gt;</span></pre>
<pre style="background-color: #fbfbfb; margin: 0em; width: 100%; font-family: consolas,'Courier New',courier,monospace; font-size: 11px;">          <span style="color: #0000ff;">&lt;</span><span style="color: #800000;">p</span><span style="color: #0000ff;">&gt;</span>Main content<span style="color: #0000ff;">&lt;/</span><span style="color: #800000;">p</span><span style="color: #0000ff;">&gt;</span></pre>
<pre style="background-color: #fbfbfb; margin: 0em; width: 100%; font-family: consolas,'Courier New',courier,monospace; font-size: 11px;">      <span style="color: #0000ff;">&lt;/</span><span style="color: #800000;">div</span><span style="color: #0000ff;">&gt;</span></pre>
<pre style="background-color: #fbfbfb; margin: 0em; width: 100%; font-family: consolas,'Courier New',courier,monospace; font-size: 11px;">      <span style="color: #0000ff;">&lt;</span><span style="color: #800000;">div</span> <span style="color: #ff0000;">id</span>=<span style="color: #0000ff;">"right-wrapper"</span> <span style="color: #ff0000;">class</span>=<span style="color: #0000ff;">"floatright"</span><span style="color: #0000ff;">&gt;</span></pre>
<pre style="background-color: #fbfbfb; margin: 0em; width: 100%; font-family: consolas,'Courier New',courier,monospace; font-size: 11px;">          <span style="color: #0000ff;">&lt;</span><span style="color: #800000;">p</span><span style="color: #0000ff;">&gt;</span>SideBar<span style="color: #0000ff;">&lt;/</span><span style="color: #800000;">p</span><span style="color: #0000ff;">&gt;</span></pre>
<pre style="background-color: #fbfbfb; margin: 0em; width: 100%; font-family: consolas,'Courier New',courier,monospace; font-size: 11px;">          <span style="color: #0000ff;">&lt;</span><span style="color: #800000;">p</span><span style="color: #0000ff;">&gt;</span>SideBar<span style="color: #0000ff;">&lt;/</span><span style="color: #800000;">p</span><span style="color: #0000ff;">&gt;</span></pre>
<pre style="background-color: #fbfbfb; margin: 0em; width: 100%; font-family: consolas,'Courier New',courier,monospace; font-size: 11px;">          <span style="color: #0000ff;">&lt;</span><span style="color: #800000;">p</span><span style="color: #0000ff;">&gt;</span>SideBar<span style="color: #0000ff;">&lt;/</span><span style="color: #800000;">p</span><span style="color: #0000ff;">&gt;</span></pre>
<pre style="background-color: #fbfbfb; margin: 0em; width: 100%; font-family: consolas,'Courier New',courier,monospace; font-size: 11px;">          <span style="color: #0000ff;">&lt;</span><span style="color: #800000;">p</span><span style="color: #0000ff;">&gt;</span>SideBar<span style="color: #0000ff;">&lt;/</span><span style="color: #800000;">p</span><span style="color: #0000ff;">&gt;</span></pre>
<pre style="background-color: #fbfbfb; margin: 0em; width: 100%; font-family: consolas,'Courier New',courier,monospace; font-size: 11px;">          <span style="color: #0000ff;">&lt;</span><span style="color: #800000;">p</span><span style="color: #0000ff;">&gt;</span>SideBar<span style="color: #0000ff;">&lt;/</span><span style="color: #800000;">p</span><span style="color: #0000ff;">&gt;</span></pre>
<pre style="background-color: #fbfbfb; margin: 0em; width: 100%; font-family: consolas,'Courier New',courier,monospace; font-size: 11px;">          <span style="color: #0000ff;">&lt;</span><span style="color: #800000;">p</span><span style="color: #0000ff;">&gt;</span>SideBar<span style="color: #0000ff;">&lt;/</span><span style="color: #800000;">p</span><span style="color: #0000ff;">&gt;</span></pre>
<pre style="background-color: #fbfbfb; margin: 0em; width: 100%; font-family: consolas,'Courier New',courier,monospace; font-size: 11px;">          <span style="color: #0000ff;">&lt;</span><span style="color: #800000;">p</span><span style="color: #0000ff;">&gt;</span>SideBar<span style="color: #0000ff;">&lt;/</span><span style="color: #800000;">p</span><span style="color: #0000ff;">&gt;</span></pre>
<pre style="background-color: #fbfbfb; margin: 0em; width: 100%; font-family: consolas,'Courier New',courier,monospace; font-size: 11px;">      <span style="color: #0000ff;">&lt;/</span><span style="color: #800000;">div</span><span style="color: #0000ff;">&gt;</span></pre>
<pre style="background-color: #fbfbfb; margin: 0em; width: 100%; font-family: consolas,'Courier New',courier,monospace; font-size: 11px;">      <span style="color: #0000ff;">&lt;</span><span style="color: #800000;">div</span> <span style="color: #ff0000;">id</span>=<span style="color: #0000ff;">"footer"</span> <span style="color: #ff0000;">class</span>=<span style="color: #0000ff;">"floatleft"</span><span style="color: #0000ff;">&gt;</span></pre>
<pre style="background-color: #fbfbfb; margin: 0em; width: 100%; font-family: consolas,'Courier New',courier,monospace; font-size: 11px;">          <span style="color: #0000ff;">&lt;</span><span style="color: #800000;">p</span><span style="color: #0000ff;">&gt;</span>Footer<span style="color: #0000ff;">&lt;/</span><span style="color: #800000;">p</span><span style="color: #0000ff;">&gt;</span></pre>
<pre style="background-color: #fbfbfb; margin: 0em; width: 100%; font-family: consolas,'Courier New',courier,monospace; font-size: 11px;">      <span style="color: #0000ff;">&lt;/</span><span style="color: #800000;">div</span><span style="color: #0000ff;">&gt;</span></pre>
<pre style="background-color: #fbfbfb; margin: 0em; width: 100%; font-family: consolas,'Courier New',courier,monospace; font-size: 11px;">  <span style="color: #0000ff;">&lt;/</span><span style="color: #800000;">div</span><span style="color: #0000ff;">&gt;</span></pre>
<pre style="background-color: #fbfbfb; margin: 0em; width: 100%; font-family: consolas,'Courier New',courier,monospace; font-size: 11px;">  <span style="color: #0000ff;">&lt;/</span><span style="color: #800000;">body</span><span style="color: #0000ff;">&gt;</span></pre>
<pre style="background-color: #fbfbfb; margin: 0em; width: 100%; font-family: consolas,'Courier New',courier,monospace; font-size: 11px;"><span style="color: #0000ff;">&lt;/</span><span style="color: #800000;">html</span><span style="color: #0000ff;">&gt;</span></pre>
</pre>
<p> </p>
<p>The next thing to look at is my “reset.css” file:</p>
<pre style="background-color: #fbfbfb; min-height: 40px; width: 588px; height: 231px; overflow: auto; border: #cecece 1px solid; padding: 5px;">
<pre style="background-color: #fbfbfb; margin: 0em; width: 100%; font-family: consolas,'Courier New',courier,monospace; font-size: 11px;"><span style="color: #008000;">/* RESET CSS FILE */</span></pre>
<pre style="background-color: #fbfbfb; margin: 0em; width: 100%; font-family: consolas,'Courier New',courier,monospace; font-size: 11px;"><span style="color: #800000;">html</span>,<span style="color: #800000;">body</span>,<span style="color: #800000;">div</span>,<span style="color: #800000;">span</span>,<span style="color: #800000;">applet</span>,<span style="color: #800000;">object</span>,<span style="color: #800000;">iframe</span>,<span style="color: #800000;">h1</span>,<span style="color: #800000;">h2</span>,<span style="color: #800000;">h3</span>,<span style="color: #800000;">h4</span>,<span style="color: #800000;">h5</span>,<span style="color: #800000;">h6</span>,<span style="color: #800000;">p</span>,<span style="color: #800000;">blockquote</span>,</pre>
<pre style="background-color: #fbfbfb; margin: 0em; width: 100%; font-family: consolas,'Courier New',courier,monospace; font-size: 11px;"><span style="color: #800000;">pre</span>,<span style="color: #800000;">a</span>,<span style="color: #800000;">abbr</span>,<span style="color: #800000;">acronym</span>,<span style="color: #800000;">address</span>,<span style="color: #800000;">big</span>,<span style="color: #800000;">cite</span>,<span style="color: #800000;">code</span>,<span style="color: #800000;">del</span>,<span style="color: #800000;">dfn</span>,<span style="color: #800000;">em</span>,<span style="color: #800000;">font</span>,<span style="color: #800000;">img</span>,<span style="color: #800000;">ins</span>,<span style="color: #800000;">kbd</span>,<span style="color: #800000;">q</span>,<span style="color: #800000;">s</span>,</pre>
<pre style="background-color: #fbfbfb; margin: 0em; width: 100%; font-family: consolas,'Courier New',courier,monospace; font-size: 11px;"><span style="color: #800000;">samp</span>,<span style="color: #800000;">small</span>,<span style="color: #800000;">strike</span>,<span style="color: #800000;">strong</span>,<span style="color: #800000;">sub</span>,<span style="color: #800000;">sup</span>,<span style="color: #800000;">tt</span>,<span style="color: #800000;">var</span>,<span style="color: #800000;">dl</span>,<span style="color: #800000;">dt</span>,<span style="color: #800000;">dd</span>,<span style="color: #800000;">ol</span>,<span style="color: #800000;">ul</span>,<span style="color: #800000;">li</span>,<span style="color: #800000;">fieldset</span>,<span style="color: #800000;">form</span>,<span style="color: #800000;">label</span>,</pre>
<pre style="background-color: #fbfbfb; margin: 0em; width: 100%; font-family: consolas,'Courier New',courier,monospace; font-size: 11px;"><span style="color: #800000;">legend</span>,<span style="color: #800000;">table</span>,<span style="color: #800000;">caption</span>,<span style="color: #800000;">tbody</span>,<span style="color: #800000;">tfoot</span>,<span style="color: #800000;">thead</span>,<span style="color: #800000;">tr</span>,<span style="color: #800000;">th</span>,<span style="color: #800000;">td</span></pre>
<pre style="background-color: #fbfbfb; margin: 0em; width: 100%; font-family: consolas,'Courier New',courier,monospace; font-size: 11px;">{<span style="color: #ff0000;">border</span>:<span style="color: #0000ff;">0</span>; <span style="color: #ff0000;">outline</span>:<span style="color: #0000ff;">0</span>; <span style="color: #ff0000;">vertical-align</span>:<span style="color: #0000ff;">middle</span>; <span style="color: #ff0000;">background</span>:<span style="color: #0000ff;">transparent</span>; <span style="color: #ff0000;">margin</span>:<span style="color: #0000ff;">0</span>; <span style="color: #ff0000;">padding</span>:<span style="color: #0000ff;">0</span>; <span style="color: #ff0000;">font-family</span>: <span style="color: #0000ff;">Verdana, Geneva, sans-serif</span>;}</pre>
<pre style="background-color: #fbfbfb; margin: 0em; width: 100%; font-family: consolas,'Courier New',courier,monospace; font-size: 11px;">* {<span style="color: #ff0000;">margin</span>:<span style="color: #0000ff;">0</span>; <span style="color: #ff0000;">padding</span>:<span style="color: #0000ff;">0</span>; }</pre>
<pre style="background-color: #fbfbfb; margin: 0em; width: 100%; font-family: consolas,'Courier New',courier,monospace; font-size: 11px;"><span style="color: #800000;">a</span> <span style="color: #800000;">img</span> { <span style="color: #ff0000;">border</span>:<span style="color: #0000ff;">0</span>; }</pre>
<pre style="background-color: #fbfbfb; margin: 0em; width: 100%; font-family: consolas,'Courier New',courier,monospace; font-size: 11px;"><span style="color: #008000;">/*
</span></pre>
<pre style="background-color: #fbfbfb; margin: 0em; width: 100%; font-family: consolas,'Courier New',courier,monospace; font-size: 11px;">This is called the clearfix "hack" to prevent container from colapsing</pre>
<pre style="background-color: #fbfbfb; margin: 0em; width: 100%; font-family: consolas,'Courier New',courier,monospace; font-size: 11px;">in on itself when all the elements inside are floated elements.</pre>
<pre style="background-color: #fbfbfb; margin: 0em; width: 100%; font-family: consolas,'Courier New',courier,monospace; font-size: 11px;">Make sure to add --[ class="container" ]-- to any object that you</pre>
<pre style="background-color: #fbfbfb; margin: 0em; width: 100%; font-family: consolas,'Courier New',courier,monospace; font-size: 11px;">don't want to colapse.</pre>
<pre style="background-color: #fbfbfb; margin: 0em; width: 100%; font-family: consolas,'Courier New',courier,monospace; font-size: 11px;">*/</pre>
<pre style="background-color: #fbfbfb; margin: 0em; width: 100%; font-family: consolas,'Courier New',courier,monospace; font-size: 11px;">.<span style="color: #800000;">container</span>:<span style="color: #800000;">after</span> { <span style="color: #ff0000;">visibility</span>: <span style="color: #0000ff;">hidden</span>; <span style="color: #ff0000;">display</span>: <span style="color: #0000ff;">block</span>; <span style="color: #ff0000;">font-size</span>:<span style="color: #0000ff;">0</span>; <span style="color: #ff0000;">content</span>: <span style="color: #0000ff;">" "</span>; <span style="color: #ff0000;">clear</span>: <span style="color: #0000ff;">both</span>; <span style="color: #ff0000;">height</span>: <span style="color: #0000ff;">0</span>; }</pre>
<pre style="background-color: #fbfbfb; margin: 0em; width: 100%; font-family: consolas,'Courier New',courier,monospace; font-size: 11px;"><span style="color: #008000;">/* start commented backlash hack \*/</span></pre>
<pre style="background-color: #fbfbfb; margin: 0em; width: 100%; font-family: consolas,'Courier New',courier,monospace; font-size: 11px;">* <span style="color: #800000;">html</span> .<span style="color: #800000;">container</span>   { <span style="color: #ff0000;">height</span>: <span style="color: #0000ff;">1%</span>;     }</pre>
<pre style="background-color: #fbfbfb; margin: 0em; width: 100%; font-family: consolas,'Courier New',courier,monospace; font-size: 11px;">.<span style="color: #800000;">container</span>          { <span style="color: #ff0000;">display</span>: <span style="color: #0000ff;">block</span>; }</pre>
<pre style="background-color: #fbfbfb; margin: 0em; width: 100%; font-family: consolas,'Courier New',courier,monospace; font-size: 11px;"><span style="color: #008000;">/* close commented backlash hack */</span></pre>
<pre style="background-color: #fbfbfb; margin: 0em; width: 100%; font-family: consolas,'Courier New',courier,monospace; font-size: 11px;"><span style="color: #008000;">/* Easy way for me to float items */</span></pre>
<pre style="background-color: #fbfbfb; margin: 0em; width: 100%; font-family: consolas,'Courier New',courier,monospace; font-size: 11px;">.<span style="color: #800000;">floatleft</span> 	{ <span style="color: #ff0000;">float</span>:<span style="color: #0000ff;">left</span>;       }</pre>
<pre style="background-color: #fbfbfb; margin: 0em; width: 100%; font-family: consolas,'Courier New',courier,monospace; font-size: 11px;">.<span style="color: #800000;">floatright</span> 	{ <span style="color: #ff0000;">float</span>:<span style="color: #0000ff;">right</span>;      }</pre>
<pre style="background-color: #fbfbfb; margin: 0em; width: 100%; font-family: consolas,'Courier New',courier,monospace; font-size: 11px;">.<span style="color: #800000;">floatmiddle</span> 	{ <span style="color: #ff0000;">margin</span>: <span style="color: #0000ff;">0px auto</span>; }</pre>
</pre>
<p> </p>
<p>The next thing to look at is main CSS file for the tutorial “default.css”:</p>
<pre style="background-color: #fbfbfb; min-height: 40px; width: 588px; height: 197px; overflow: auto; border: #cecece 1px solid; padding: 5px;">
<pre style="background-color: #fbfbfb; margin: 0em; width: 100%; font-family: consolas,'Courier New',courier,monospace; font-size: 11px;"><span style="color: #008000;">/* Physical Styling */</span></pre>
<pre style="background-color: #fbfbfb; margin: 0em; width: 100%; font-family: consolas,'Courier New',courier,monospace; font-size: 11px;"><span style="color: #800000;">body</span> { <span style="color: #ff0000;">text-align</span>:<span style="color: #0000ff;">center</span>; }</pre>
<pre style="background-color: #fbfbfb; margin: 0em; width: 100%; font-family: consolas,'Courier New',courier,monospace; font-size: 11px;"><span style="color: #008000;">/* Font Styling */</span></pre>
<pre style="background-color: #fbfbfb; margin: 0em; width: 100%; font-family: consolas,'Courier New',courier,monospace; font-size: 11px;"><span style="color: #800000;">h1</span>  { <span style="color: #ff0000;">font-size</span>: <span style="color: #0000ff;">45px</span>; <span style="color: #ff0000;">color</span>: <span style="color: #0000ff;">black</span>; }</pre>
<pre style="background-color: #fbfbfb; margin: 0em; width: 100%; font-family: consolas,'Courier New',courier,monospace; font-size: 11px;"><span style="color: #800000;">h2</span>  { <span style="color: #ff0000;">font-size</span>: <span style="color: #0000ff;">35px</span>;}</pre>
<pre style="background-color: #fbfbfb; margin: 0em; width: 100%; font-family: consolas,'Courier New',courier,monospace; font-size: 11px;"><span style="color: #800000;">h3</span>  { <span style="color: #ff0000;">font-size</span>: <span style="color: #0000ff;">30px</span>; <span style="color: #ff0000;">font-style</span>: <span style="color: #0000ff;">italic</span>; }</pre>
<pre style="background-color: #fbfbfb; margin: 0em; width: 100%; font-family: consolas,'Courier New',courier,monospace; font-size: 11px;"><span style="color: #800000;">p</span>   { <span style="color: #ff0000;">font-size</span>: <span style="color: #0000ff;">18px</span>;}</pre>
<pre style="background-color: #fbfbfb; margin: 0em; width: 100%; font-family: consolas,'Courier New',courier,monospace; font-size: 11px;">.<span style="color: #800000;">red</span> { <span style="color: #ff0000;">color</span>: <span style="color: #0000ff;">red</span>; }</pre>
<pre style="background-color: #fbfbfb; margin: 0em; width: 100%; font-family: consolas,'Courier New',courier,monospace; font-size: 11px;">.<span style="color: #800000;">bold</span> { <span style="color: #ff0000;">font-weight</span>: <span style="color: #0000ff;">bold</span>; }</pre>
<pre style="background-color: #fbfbfb; margin: 0em; width: 100%; font-family: consolas,'Courier New',courier,monospace; font-size: 11px;"><span style="color: #800000;">#main-wrapper</span> { <span style="color: #ff0000;">width</span>: <span style="color: #0000ff;">600px</span>;  <span style="color: #ff0000;">margin</span>: <span style="color: #0000ff;">0 auto</span>; <span style="color: #ff0000;">text-align</span>: <span style="color: #0000ff;">left</span>; <span style="color: #ff0000;">background-color</span>: <span style="color: #0000ff;">aqua</span>; }</pre>
<pre style="background-color: #fbfbfb; margin: 0em; width: 100%; font-family: consolas,'Courier New',courier,monospace; font-size: 11px;"><span style="color: #800000;">#header</span> { <span style="color: #ff0000;">width</span>: <span style="color: #0000ff;">600px</span>; <span style="color: #ff0000;">background-color</span>: <span style="color: #0000ff;">green</span>; }</pre>
<pre style="background-color: #fbfbfb; margin: 0em; width: 100%; font-family: consolas,'Courier New',courier,monospace; font-size: 11px;"><span style="color: #800000;">#main-content</span> { <span style="color: #ff0000;">width</span>: <span style="color: #0000ff;">400px</span>; <span style="color: #ff0000;">background-color</span>: <span style="color: #0000ff;">gray</span>; <span style="color: #ff0000;">background-color</span>: <span style="color: #0000ff;">teal</span>; }</pre>
<pre style="background-color: #fbfbfb; margin: 0em; width: 100%; font-family: consolas,'Courier New',courier,monospace; font-size: 11px;"><span style="color: #800000;">#right-wrapper</span> { <span style="color: #ff0000;">width</span>: <span style="color: #0000ff;">200px</span>; <span style="color: #ff0000;">background-color</span>: <span style="color: #0000ff;">red</span>; <span style="color: #ff0000;">clear</span>: <span style="color: #0000ff;">right</span>;  }</pre>
<pre style="background-color: #fbfbfb; margin: 0em; width: 100%; font-family: consolas,'Courier New',courier,monospace; font-size: 11px;"><span style="color: #800000;">#footer</span> { <span style="color: #ff0000;">width</span>: <span style="color: #0000ff;">600px</span>; <span style="color: #ff0000;">background-color</span>: <span style="color: #0000ff;">lime</span>; }</pre>
</pre>
<p> </p>
<p>Some of you might not be aware but you can actually have more then one CSS file linked in your HTML file. The first CSS file named reset.css basically does what it’s named. It resets all the items so that your code *SHOULD* look similar in all browsers without a multitude of hacks or IF statements. I also created some custom classes that I tend to use over and over again. Things like floating a DIV left or right is done all the time. I wanted a way of knowing inside the HTML code whether an element is floated or not. I’ve also included 1 hack to prevent container collapse. The only thing you have to do is in the HTML file add the class=“container” to the container in question that is collapsing.</p>
<p>Note in advance please excuse the horrible colors I chose for the background of the elements!! I did it so that it would be fairly obvious so you could follow along easier!!</p>
<p>Here’s what the 3 files create:</p>
<p><a href="http://jaredheinrichs.com/wp-content/uploads/2010/03/image4.png"><img style="display: inline; border: 0px;" title="image" src="http://jaredheinrichs.com/wp-content/uploads/2010/03/image_thumb3.png" border="0" alt="image" width="612" height="266" /></a></p>
<p>*Educational NOTE* – Remember when I talked about the DIV collapse hack I included in the reset.css file? If I didn’t add that the light blue (cyan) would not show up! It would be the same color as the body background which in this case is white.</p>
<p>As you can see from the HTML file “Header”,”Main-Content”, and “Footer” are all floated left.</p>
<p>You should also see that the “side-wrapper” is floated to the right.</p>
<p>What happens if we changed the “right-wrapper” clear property from “clear: right” to “clear:left” or “clear:both”??</p>
<p><a href="http://jaredheinrichs.com/wp-content/uploads/2010/03/image5.png"><img style="display: inline; border: 0px;" title="image" src="http://jaredheinrichs.com/wp-content/uploads/2010/03/image_thumb4.png" border="0" alt="image" width="610" height="291" /></a></p>
<p>Did you notice that the “Side-wrapper” is no longer in the “correct” position? So what is happening here? Well we know the “Cyan” color is the background color of the wrapper that is containing all the elements in place. Basically what is happening in this situation is the “Side-wrapper” is dropped down below the “main-content” element because the float has been told “Don’t continue the float on the left hand side. Right after the last element continue drawing this element.</p>
<p>Here’s something else to consider. What would the layout look like if the “Side-wrapper” is floated left instead of floated right? Would it look the same?</p>
<p>Nope. All the elements would look like none of them were floated.</p>
<p><a href="http://jaredheinrichs.com/wp-content/uploads/2010/03/image6.png"><img style="display: inline; border: 0px;" title="image" src="http://jaredheinrichs.com/wp-content/uploads/2010/03/image_thumb5.png" border="0" alt="image" width="611" height="293" /></a></p>
<p>Did you have the “ah ha!!” Moment yet?</p>
<p>In closing the “clear” property is used to breakup the HTML floats flow.</p>
]]></content:encoded>
			<wfw:commentRss>http://jaredheinrichs.com/visual-tutorial-on-the-clear-property.html/feed</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>How you can use HTML5 now even with older browsers</title>
		<link>http://jaredheinrichs.com/how-you-can-use-html5-now-even-with-older-browsers.html</link>
		<comments>http://jaredheinrichs.com/how-you-can-use-html5-now-even-with-older-browsers.html#comments</comments>
		<pubDate>Tue, 02 Feb 2010 04:01:57 +0000</pubDate>
		<dc:creator>Jared Heinrichs</dc:creator>
				<category><![CDATA[CSS]]></category>
		<category><![CDATA[HTML]]></category>

		<guid isPermaLink="false">http://jaredheinrichs.com/how-you-can-use-html5-now-even-with-older-browsers.html</guid>
		<description><![CDATA[I’ve been reading up on HTML5 lately. I’ve got to say that the HTML5 code is so much cleaner. Unfortunately browsers like Internet Explorer 6 don’t understand some of the new elements that make up HTML 5 unless you tell &#8230; <a href="http://jaredheinrichs.com/how-you-can-use-html5-now-even-with-older-browsers.html">Continue reading <span class="meta-nav">&#8594;</span></a>]]></description>
			<content:encoded><![CDATA[<p>I’ve been reading up on HTML5 lately. I’ve got to say that the HTML5 code is so much cleaner. Unfortunately browsers like Internet Explorer 6 don’t understand some of the new elements that make up HTML 5 unless you tell it to them yourself.</p>
<p>What are some of the new elements you say? Well without further adieu here are the main additions to web layout:</p>
<ul>
<li>header</li>
<li>section</li>
<li>footer</li>
<li>aside</li>
<li>nav</li>
<li>article</li>
<li>figure</li>
</ul>
<p>You might be asking what is the big deal with these being added to HTML5? Well up until now most people would do something similar to this to create a header section:</p>
<pre style="border-bottom: #cecece 1px solid; border-left: #cecece 1px solid; padding-bottom: 5px; background-color: #fbfbfb; min-height: 40px; padding-left: 5px; width: 615px; padding-right: 5px; overflow: auto; border-top: #cecece 1px solid; border-right: #cecece 1px solid; padding-top: 5px">
<pre style="background-color: #fbfbfb; margin: 0em; width: 100%; font-family: consolas,&#39;Courier New&#39;,courier,monospace; font-size: 12px"><span style="color: #0000ff">&lt;</span><span style="color: #800000">div</span> <span style="color: #ff0000">id</span>=<span style="color: #0000ff">&quot;header&quot;</span><span style="color: #0000ff">&gt;</span>
</pre>
<pre style="background-color: #fbfbfb; margin: 0em; width: 100%; font-family: consolas,&#39;Courier New&#39;,courier,monospace; font-size: 12px">   some code goes here
</pre>
<blockquote><pre style="background-color: #fbfbfb; margin: 0em; width: 100%; font-family: consolas,&#39;Courier New&#39;,courier,monospace; font-size: 12px"><span style="color: #0000ff">&lt;/</span><span style="color: #800000">div</span><span style="color: #0000ff">&gt;</span></pre>
</blockquote>
</pre>
<p>&#160;</p>
<p>Things like search engines don’t really understand that the last piece of code is the header. To top it off when pages start getting a ton of &lt;div&gt;’s, it makes it much harder to read the code then what HTML5 brings to the table. </p>
<p>Here is the same HTML container but now we are using the “header” section that is part of HTML5:</p>
<pre style="border-bottom: #cecece 1px solid; border-left: #cecece 1px solid; padding-bottom: 5px; background-color: #fbfbfb; min-height: 40px; padding-left: 5px; width: 615px; padding-right: 5px; overflow: auto; border-top: #cecece 1px solid; border-right: #cecece 1px solid; padding-top: 5px">
<pre style="background-color: #fbfbfb; margin: 0em; width: 100%; font-family: consolas,&#39;Courier New&#39;,courier,monospace; font-size: 12px"><span style="color: #0000ff">&lt;</span><span style="color: #800000">header</span><span style="color: #0000ff">&gt;</span>
</pre>
<pre style="background-color: #fbfbfb; margin: 0em; width: 100%; font-family: consolas,&#39;Courier New&#39;,courier,monospace; font-size: 12px">    some code goes here...
</pre>
<pre style="background-color: #fbfbfb; margin: 0em; width: 100%; font-family: consolas,&#39;Courier New&#39;,courier,monospace; font-size: 12px"><span style="color: #0000ff">&lt;/</span><span style="color: #800000">header</span><span style="color: #0000ff">&gt;</span></pre>
</pre>
<p>&#160;</p>
<p>HTML5 also helps to make the CSS easier read and follow. Here is the example of css for both the &lt;div&gt; approach and the new HTML5 approach.</p>
<p>Old &lt;div&gt; approach:</p>
<pre style="border-bottom: #cecece 1px solid; border-left: #cecece 1px solid; padding-bottom: 5px; background-color: #fbfbfb; min-height: 40px; padding-left: 5px; width: 615px; padding-right: 5px; overflow: auto; border-top: #cecece 1px solid; border-right: #cecece 1px solid; padding-top: 5px">
<pre style="background-color: #fbfbfb; margin: 0em; width: 100%; font-family: consolas,&#39;Courier New&#39;,courier,monospace; font-size: 12px"><span style="color: #800000">#header</span>    { <span style="color: #ff0000">width</span>:<span style="color: #0000ff">1000px</span>; <span style="color: #ff0000">height</span>: <span style="color: #0000ff">300px</span>; }
</pre>
<pre style="background-color: #fbfbfb; margin: 0em; width: 100%; font-family: consolas,&#39;Courier New&#39;,courier,monospace; font-size: 12px"><span style="color: #800000">#header</span> <span style="color: #800000">h1</span> { <span style="color: #ff0000">font</span>: <span style="color: #0000ff">bold 20px Helvetica, Sans-serif</span>; <span style="color: #ff0000">margin</span>: <span style="color: #0000ff">0 0 10px 0</span>; }
</pre>
<pre style="background-color: #fbfbfb; margin: 0em; width: 100%; font-family: consolas,&#39;Courier New&#39;,courier,monospace; font-size: 12px"></pre>
<pre style="background-color: #fbfbfb; margin: 0em; width: 100%; font-family: consolas,&#39;Courier New&#39;,courier,monospace; font-size: 12px"><span style="color: #800000">#nav</span>    { <span style="color: #ff0000">width</span>:1000px }
</pre>
<pre style="background-color: #fbfbfb; margin: 0em; width: 100%; font-family: consolas,&#39;Courier New&#39;,courier,monospace; font-size: 12px"><span style="color: #800000">#footer</span> { <span style="color: #ff0000">width</span>:1000px }</pre>
</pre>
<p>&#160;</p>
<p>New HTML5 approach:</p>
<pre style="border-bottom: #cecece 1px solid; border-left: #cecece 1px solid; padding-bottom: 5px; background-color: #fbfbfb; min-height: 40px; padding-left: 5px; width: 615px; padding-right: 5px; overflow: auto; border-top: #cecece 1px solid; border-right: #cecece 1px solid; padding-top: 5px">
<pre style="background-color: #fbfbfb; margin: 0em; width: 100%; font-family: consolas,&#39;Courier New&#39;,courier,monospace; font-size: 12px"><span style="color: #800000">header</span> { <span style="color: #ff0000">width</span>:<span style="color: #0000ff">1000px</span>; <span style="color: #ff0000">height</span>: <span style="color: #0000ff">300px</span>; }
</pre>
<pre style="background-color: #fbfbfb; margin: 0em; width: 100%; font-family: consolas,&#39;Courier New&#39;,courier,monospace; font-size: 12px"><span style="color: #800000">header</span> <span style="color: #800000">h1</span> { <span style="color: #ff0000">font</span>: <span style="color: #0000ff">bold 20px Helvetica, Sans-serif</span>; <span style="color: #ff0000">margin</span>: <span style="color: #0000ff">0 0 10px 0</span>; }
</pre>
<pre style="background-color: #fbfbfb; margin: 0em; width: 100%; font-family: consolas,&#39;Courier New&#39;,courier,monospace; font-size: 12px"></pre>
<pre style="background-color: #fbfbfb; margin: 0em; width: 100%; font-family: consolas,&#39;Courier New&#39;,courier,monospace; font-size: 12px"><span style="color: #800000">nav</span>    { <span style="color: #ff0000">width</span>:1000px }
</pre>
<pre style="background-color: #fbfbfb; margin: 0em; width: 100%; font-family: consolas,&#39;Courier New&#39;,courier,monospace; font-size: 12px"><span style="color: #800000">footer</span> { <span style="color: #ff0000">width</span>:1000px }</pre>
</pre>
<p>&#160;</p>
<p>As you can see the new elements will provide a type of meta data to the browser and search engines letting it know where the main content is on the page. This should help with SEO (search engine optimization).</p>
<p>For most browsers you will need to add the elements to the HTML document by doing three things:</p>
<p>Set the new Doc Type:</p>
<pre style="border-bottom: #cecece 1px solid; border-left: #cecece 1px solid; padding-bottom: 5px; background-color: #fbfbfb; min-height: 40px; padding-left: 5px; width: 615px; padding-right: 5px; overflow: auto; border-top: #cecece 1px solid; border-right: #cecece 1px solid; padding-top: 5px">
<pre style="background-color: #fbfbfb; margin: 0em; width: 100%; font-family: consolas,&#39;Courier New&#39;,courier,monospace; font-size: 12px"><span style="color: #0000ff">&lt;</span>!DOCTYPE html<span style="color: #0000ff">&gt;</span></pre>
</pre>
<p>&#160;</p>
<p>Second we have to tell the browser to treat the new items as Block Type elements using CSS. Once we create the CSS file all we have to do then is to link the CSS to the page we want to code in HTML5. Copy this css and save it as HTML5.css:</p>
<pre style="border-bottom: #cecece 1px solid; border-left: #cecece 1px solid; padding-bottom: 5px; background-color: #fbfbfb; min-height: 40px; padding-left: 5px; width: 615px; padding-right: 5px; overflow: auto; border-top: #cecece 1px solid; border-right: #cecece 1px solid; padding-top: 5px">
<pre style="background-color: #fbfbfb; margin: 0em; width: 100%; font-family: consolas,&#39;Courier New&#39;,courier,monospace; font-size: 12px"><span style="color: #800000">header</span>, <span style="color: #800000">section</span>, <span style="color: #800000">footer</span>, <span style="color: #800000">aside</span>, <span style="color: #800000">nav</span>, <span style="color: #800000">article</span>, <span style="color: #800000">figure</span> {
</pre>
<pre style="background-color: #fbfbfb; margin: 0em; width: 100%; font-family: consolas,&#39;Courier New&#39;,courier,monospace; font-size: 12px">	<span style="color: #ff0000">display</span>:<span style="color: #0000ff">block</span>;
</pre>
<pre style="background-color: #fbfbfb; margin: 0em; width: 100%; font-family: consolas,&#39;Courier New&#39;,courier,monospace; font-size: 12px">}</pre>
</pre>
<p>&#160;</p>
<p>The third thing you will have to do is to add some JavaScript to the beginning of your webpage to add these items to the DOM list in your browser. (Incase it isn’t supported yet)</p>
<pre style="border-bottom: #cecece 1px solid; border-left: #cecece 1px solid; padding-bottom: 5px; background-color: #fbfbfb; min-height: 40px; padding-left: 5px; width: 615px; padding-right: 5px; overflow: auto; border-top: #cecece 1px solid; border-right: #cecece 1px solid; padding-top: 5px">
<pre style="background-color: #fbfbfb; margin: 0em; width: 100%; font-family: consolas,&#39;Courier New&#39;,courier,monospace; font-size: 12px"><span style="color: #008000">&lt;!--[if IE]&gt;
</pre>
<pre style="background-color: #fbfbfb; margin: 0em; width: 100%; font-family: consolas,&#39;Courier New&#39;,courier,monospace; font-size: 12px">    &lt;script src=&quot;http://html5shiv.googlecode.com/svn/trunk/html5.js&quot;&gt;&lt;/script&gt;
</pre>
<pre style="background-color: #fbfbfb; margin: 0em; width: 100%; font-family: consolas,&#39;Courier New&#39;,courier,monospace; font-size: 12px">&lt;![endif]—&gt;</span>   </pre>
</pre>
<p>&#160;</p>
<p>As you can see in the example above we finally a doc type that a mortal can actually remember! Ok. Time to wrap this one up. Here’s a small FULL example of HTML5 and the CSS that goes with it:</p>
<p>HTML5 (index.html)</p>
<pre style="border-bottom: #cecece 1px solid; border-left: #cecece 1px solid; padding-bottom: 5px; background-color: #fbfbfb; min-height: 40px; padding-left: 5px; width: 615px; padding-right: 5px; overflow: auto; border-top: #cecece 1px solid; border-right: #cecece 1px solid; padding-top: 5px">
<pre style="background-color: #fbfbfb; margin: 0em; width: 100%; font-family: consolas,&#39;Courier New&#39;,courier,monospace; font-size: 12px"><span style="color: #0000ff">&lt;</span>!DOCTYPE html<span style="color: #0000ff">&gt;</span>
</pre>
<pre style="background-color: #fbfbfb; margin: 0em; width: 100%; font-family: consolas,&#39;Courier New&#39;,courier,monospace; font-size: 12px"><span style="color: #0000ff">&lt;</span><span style="color: #800000">html</span> <span style="color: #ff0000">lang</span>=<span style="color: #0000ff">&quot;en&quot;</span><span style="color: #0000ff">&gt;</span>
</pre>
<pre style="background-color: #fbfbfb; margin: 0em; width: 100%; font-family: consolas,&#39;Courier New&#39;,courier,monospace; font-size: 12px"></pre>
<pre style="background-color: #fbfbfb; margin: 0em; width: 100%; font-family: consolas,&#39;Courier New&#39;,courier,monospace; font-size: 12px"><span style="color: #0000ff">&lt;</span><span style="color: #800000">head</span><span style="color: #0000ff">&gt;</span>
</pre>
<pre style="background-color: #fbfbfb; margin: 0em; width: 100%; font-family: consolas,&#39;Courier New&#39;,courier,monospace; font-size: 12px">    <span style="color: #0000ff">&lt;</span><span style="color: #800000">meta</span> <span style="color: #ff0000">charset</span>=<span style="color: #0000ff">&quot;utf-8&quot;</span> <span style="color: #0000ff">/&gt;</span>
</pre>
<pre style="background-color: #fbfbfb; margin: 0em; width: 100%; font-family: consolas,&#39;Courier New&#39;,courier,monospace; font-size: 12px"></pre>
<pre style="background-color: #fbfbfb; margin: 0em; width: 100%; font-family: consolas,&#39;Courier New&#39;,courier,monospace; font-size: 12px">    <span style="color: #0000ff">&lt;</span><span style="color: #800000">title</span><span style="color: #0000ff">&gt;</span>HTML5 Demo<span style="color: #0000ff">&lt;/</span><span style="color: #800000">title</span><span style="color: #0000ff">&gt;</span>
</pre>
<pre style="background-color: #fbfbfb; margin: 0em; width: 100%; font-family: consolas,&#39;Courier New&#39;,courier,monospace; font-size: 12px">
</pre>
<pre style="background-color: #fbfbfb; margin: 0em; width: 100%; font-family: consolas,&#39;Courier New&#39;,courier,monospace; font-size: 12px">    <span style="color: #0000ff">&lt;</span><span style="color: #800000">link</span> <span style="color: #ff0000">href</span>=<span style="color: #0000ff">&quot;stylesheet/reset.css&quot;</span> <span style="color: #ff0000">rel</span>=<span style="color: #0000ff">&quot;stylesheet&quot;</span> <span style="color: #ff0000">type</span>=<span style="color: #0000ff">&quot;text/css&quot;</span><span style="color: #0000ff">&gt;</span>
</pre>
<pre style="background-color: #fbfbfb; margin: 0em; width: 100%; font-family: consolas,&#39;Courier New&#39;,courier,monospace; font-size: 12px">    <span style="color: #0000ff">&lt;</span><span style="color: #800000">link</span> <span style="color: #ff0000">href</span>=<span style="color: #0000ff">&quot;stylesheet/html5.css&quot;</span> <span style="color: #ff0000">rel</span>=<span style="color: #0000ff">&quot;stylesheet&quot;</span> <span style="color: #ff0000">type</span>=<span style="color: #0000ff">&quot;text/css&quot;</span><span style="color: #0000ff">&gt;</span>
</pre>
<pre style="background-color: #fbfbfb; margin: 0em; width: 100%; font-family: consolas,&#39;Courier New&#39;,courier,monospace; font-size: 12px">    <span style="color: #0000ff">&lt;</span><span style="color: #800000">link</span> <span style="color: #ff0000">href</span>=<span style="color: #0000ff">&quot;stylesheet/master.css&quot;</span> <span style="color: #ff0000">rel</span>=<span style="color: #0000ff">&quot;stylesheet&quot;</span> <span style="color: #ff0000">type</span>=<span style="color: #0000ff">&quot;text/css&quot;</span><span style="color: #0000ff">&gt;</span>
</pre>
<pre style="background-color: #fbfbfb; margin: 0em; width: 100%; font-family: consolas,&#39;Courier New&#39;,courier,monospace; font-size: 12px">
</pre>
<pre style="background-color: #fbfbfb; margin: 0em; width: 100%; font-family: consolas,&#39;Courier New&#39;,courier,monospace; font-size: 12px">
</pre>
<pre style="background-color: #fbfbfb; margin: 0em; width: 100%; font-family: consolas,&#39;Courier New&#39;,courier,monospace; font-size: 12px">    <span style="color: #008000">&lt;!--[if IE]&gt;
</pre>
<pre style="background-color: #fbfbfb; margin: 0em; width: 100%; font-family: consolas,&#39;Courier New&#39;,courier,monospace; font-size: 12px">    	&lt;script src=&quot;http://html5shiv.googlecode.com/svn/trunk/html5.js&quot;&gt;&lt;/script&gt;
</pre>
<pre style="background-color: #fbfbfb; margin: 0em; width: 100%; font-family: consolas,&#39;Courier New&#39;,courier,monospace; font-size: 12px">    &lt;![endif]--&gt;</span>
</pre>
<pre style="background-color: #fbfbfb; margin: 0em; width: 100%; font-family: consolas,&#39;Courier New&#39;,courier,monospace; font-size: 12px"><span style="color: #0000ff">&lt;/</span><span style="color: #800000">head</span><span style="color: #0000ff">&gt;</span>
</pre>
<pre style="background-color: #fbfbfb; margin: 0em; width: 100%; font-family: consolas,&#39;Courier New&#39;,courier,monospace; font-size: 12px"></pre>
<pre style="background-color: #fbfbfb; margin: 0em; width: 100%; font-family: consolas,&#39;Courier New&#39;,courier,monospace; font-size: 12px"></pre>
<pre style="background-color: #fbfbfb; margin: 0em; width: 100%; font-family: consolas,&#39;Courier New&#39;,courier,monospace; font-size: 12px"><span style="color: #0000ff">&lt;</span><span style="color: #800000">body</span><span style="color: #0000ff">&gt;</span><span style="color: #0000ff">&lt;</span><span style="color: #800000">div</span> <span style="color: #ff0000">id</span>=<span style="color: #0000ff">&quot;page&quot;</span> <span style="color: #ff0000">class</span>=<span style="color: #0000ff">&quot;container floatmiddle&quot;</span><span style="color: #0000ff">&gt;</span>
</pre>
<pre style="background-color: #fbfbfb; margin: 0em; width: 100%; font-family: consolas,&#39;Courier New&#39;,courier,monospace; font-size: 12px"></pre>
<pre style="background-color: #fbfbfb; margin: 0em; width: 100%; font-family: consolas,&#39;Courier New&#39;,courier,monospace; font-size: 12px">    <span style="color: #0000ff">&lt;</span><span style="color: #800000">header</span><span style="color: #0000ff">&gt;</span>
</pre>
<pre style="background-color: #fbfbfb; margin: 0em; width: 100%; font-family: consolas,&#39;Courier New&#39;,courier,monospace; font-size: 12px">    	<span style="color: #0000ff">&lt;</span><span style="color: #800000">h1</span><span style="color: #0000ff">&gt;</span>The title of the webpage<span style="color: #0000ff">&lt;/</span><span style="color: #800000">h1</span><span style="color: #0000ff">&gt;</span>
</pre>
<pre style="background-color: #fbfbfb; margin: 0em; width: 100%; font-family: consolas,&#39;Courier New&#39;,courier,monospace; font-size: 12px">    <span style="color: #0000ff">&lt;/</span><span style="color: #800000">header</span><span style="color: #0000ff">&gt;</span>
</pre>
<pre style="background-color: #fbfbfb; margin: 0em; width: 100%; font-family: consolas,&#39;Courier New&#39;,courier,monospace; font-size: 12px">
</pre>
<pre style="background-color: #fbfbfb; margin: 0em; width: 100%; font-family: consolas,&#39;Courier New&#39;,courier,monospace; font-size: 12px">    <span style="color: #0000ff">&lt;</span><span style="color: #800000">nav</span> <span style="color: #ff0000">class</span>=<span style="color: #0000ff">&quot;container&quot;</span><span style="color: #0000ff">&gt;</span>
</pre>
<pre style="background-color: #fbfbfb; margin: 0em; width: 100%; font-family: consolas,&#39;Courier New&#39;,courier,monospace; font-size: 12px">    	<span style="color: #0000ff">&lt;</span><span style="color: #800000">p</span> <span style="color: #ff0000">class</span>=<span style="color: #0000ff">&quot;floatleft&quot;</span><span style="color: #0000ff">&gt;</span>Left<span style="color: #0000ff">&lt;/</span><span style="color: #800000">p</span><span style="color: #0000ff">&gt;</span>
</pre>
<pre style="background-color: #fbfbfb; margin: 0em; width: 100%; font-family: consolas,&#39;Courier New&#39;,courier,monospace; font-size: 12px">        <span style="color: #0000ff">&lt;</span><span style="color: #800000">p</span> <span style="color: #ff0000">class</span>=<span style="color: #0000ff">&quot;floatright&quot;</span><span style="color: #0000ff">&gt;</span>Right<span style="color: #0000ff">&lt;/</span><span style="color: #800000">p</span><span style="color: #0000ff">&gt;</span>
</pre>
<pre style="background-color: #fbfbfb; margin: 0em; width: 100%; font-family: consolas,&#39;Courier New&#39;,courier,monospace; font-size: 12px">    <span style="color: #0000ff">&lt;/</span><span style="color: #800000">nav</span><span style="color: #0000ff">&gt;</span>
</pre>
<pre style="background-color: #fbfbfb; margin: 0em; width: 100%; font-family: consolas,&#39;Courier New&#39;,courier,monospace; font-size: 12px">
</pre>
<pre style="background-color: #fbfbfb; margin: 0em; width: 100%; font-family: consolas,&#39;Courier New&#39;,courier,monospace; font-size: 12px">    <span style="color: #0000ff">&lt;</span><span style="color: #800000">section</span><span style="color: #0000ff">&gt;</span>
</pre>
<pre style="background-color: #fbfbfb; margin: 0em; width: 100%; font-family: consolas,&#39;Courier New&#39;,courier,monospace; font-size: 12px">    	<span style="color: #0000ff">&lt;</span><span style="color: #800000">p</span><span style="color: #0000ff">&gt;</span>This is a test<span style="color: #0000ff">&lt;/</span><span style="color: #800000">p</span><span style="color: #0000ff">&gt;</span>
</pre>
<pre style="background-color: #fbfbfb; margin: 0em; width: 100%; font-family: consolas,&#39;Courier New&#39;,courier,monospace; font-size: 12px">    <span style="color: #0000ff">&lt;/</span><span style="color: #800000">section</span><span style="color: #0000ff">&gt;</span>
</pre>
<pre style="background-color: #fbfbfb; margin: 0em; width: 100%; font-family: consolas,&#39;Courier New&#39;,courier,monospace; font-size: 12px">
</pre>
<pre style="background-color: #fbfbfb; margin: 0em; width: 100%; font-family: consolas,&#39;Courier New&#39;,courier,monospace; font-size: 12px">    <span style="color: #0000ff">&lt;</span><span style="color: #800000">footer</span><span style="color: #0000ff">&gt;</span>
</pre>
<pre style="background-color: #fbfbfb; margin: 0em; width: 100%; font-family: consolas,&#39;Courier New&#39;,courier,monospace; font-size: 12px">    	<span style="color: #0000ff">&lt;</span><span style="color: #800000">p</span><span style="color: #0000ff">&gt;</span>This is the footer<span style="color: #0000ff">&lt;/</span><span style="color: #800000">p</span><span style="color: #0000ff">&gt;</span>
</pre>
<pre style="background-color: #fbfbfb; margin: 0em; width: 100%; font-family: consolas,&#39;Courier New&#39;,courier,monospace; font-size: 12px">    <span style="color: #0000ff">&lt;/</span><span style="color: #800000">footer</span><span style="color: #0000ff">&gt;</span>
</pre>
<pre style="background-color: #fbfbfb; margin: 0em; width: 100%; font-family: consolas,&#39;Courier New&#39;,courier,monospace; font-size: 12px"></pre>
<pre style="background-color: #fbfbfb; margin: 0em; width: 100%; font-family: consolas,&#39;Courier New&#39;,courier,monospace; font-size: 12px"><span style="color: #0000ff">&lt;/</span><span style="color: #800000">div</span><span style="color: #0000ff">&gt;</span><span style="color: #0000ff">&lt;/</span><span style="color: #800000">body</span><span style="color: #0000ff">&gt;</span>
</pre>
<pre style="background-color: #fbfbfb; margin: 0em; width: 100%; font-family: consolas,&#39;Courier New&#39;,courier,monospace; font-size: 12px"><span style="color: #0000ff">&lt;/</span><span style="color: #800000">html</span><span style="color: #0000ff">&gt;</span>
</pre>
<pre style="background-color: #fbfbfb; margin: 0em; width: 100%; font-family: consolas,&#39;Courier New&#39;,courier,monospace; font-size: 12px"></pre>
</pre>
<p><a href="http://jaredheinrichs.com/how-to-use-css-to-reset-the-default-browser-element-settings.html">reset.css</a>&#160; &lt;– Click here for the code</p>
<p>HTML5 – See above for the code.</p>
<p>master.css</p>
<pre style="border-bottom: #cecece 1px solid; border-left: #cecece 1px solid; padding-bottom: 5px; background-color: #fbfbfb; min-height: 40px; padding-left: 5px; width: 615px; padding-right: 5px; overflow: auto; border-top: #cecece 1px solid; border-right: #cecece 1px solid; padding-top: 5px">
<pre style="background-color: #fbfbfb; margin: 0em; width: 100%; font-family: consolas,&#39;Courier New&#39;,courier,monospace; font-size: 12px"><span style="color: #800000">body</span>    { <span style="color: #ff0000">background</span>:<span style="color: #0000ff">f4f4f4</span>; <span style="color: #ff0000">font</span>: <span style="color: #0000ff">15px/1.5 Georgia,serif</span>;}
</pre>
<pre style="background-color: #fbfbfb; margin: 0em; width: 100%; font-family: consolas,&#39;Courier New&#39;,courier,monospace; font-size: 12px"><span style="color: #800000">a</span>       { <span style="color: #ff0000">text-decoration</span>: <span style="color: #0000ff">none</span>; }
</pre>
<pre style="background-color: #fbfbfb; margin: 0em; width: 100%; font-family: consolas,&#39;Courier New&#39;,courier,monospace; font-size: 12px"></pre>
<pre style="background-color: #fbfbfb; margin: 0em; width: 100%; font-family: consolas,&#39;Courier New&#39;,courier,monospace; font-size: 12px"><span style="color: #800000">header</span> <span style="color: #800000">h1</span> { <span style="color: #ff0000">font</span>: <span style="color: #0000ff">bold 30px Helvetica, Sans-serif</span>; <span style="color: #ff0000">margin</span>: <span style="color: #0000ff">0 0 5px 0</span>; }
</pre>
<pre style="background-color: #fbfbfb; margin: 0em; width: 100%; font-family: consolas,&#39;Courier New&#39;,courier,monospace; font-size: 12px"><span style="color: #800000">header</span> <span style="color: #800000">h2</span> { <span style="color: #ff0000">font</span>: <span style="color: #0000ff">bold 20px Helvetica, Sans-serif</span>; <span style="color: #ff0000">margin</span>: <span style="color: #0000ff">0 0 10px 0</span>; }
</pre>
<pre style="background-color: #fbfbfb; margin: 0em; width: 100%; font-family: consolas,&#39;Courier New&#39;,courier,monospace; font-size: 12px"></pre>
<pre style="background-color: #fbfbfb; margin: 0em; width: 100%; font-family: consolas,&#39;Courier New&#39;,courier,monospace; font-size: 12px"><span style="color: #800000">#page</span> { <span style="color: #ff0000">width</span>: <span style="color: #0000ff">500px</span>; <span style="color: #ff0000">background</span>:#CCC }</pre>
</pre>
<p>&#160;</p>
<p>This will produce something that will look similar to this:</p>
<p><img style="border-bottom: 0px; border-left: 0px; display: inline; border-top: 0px; border-right: 0px" title="image" border="0" alt="image" src="http://jaredheinrichs.com/wp-content/uploads/2010/02/image.png" width="560" height="159" /></p>
<p>I hope you found this informative <img src='http://jaredheinrichs.com/wp-includes/images/smilies/icon_smile.gif' alt=':)' class='wp-smiley' />  </p>
]]></content:encoded>
			<wfw:commentRss>http://jaredheinrichs.com/how-you-can-use-html5-now-even-with-older-browsers.html/feed</wfw:commentRss>
		<slash:comments>1</slash:comments>
		</item>
		<item>
		<title>How to use CSS to reset the default browser element settings</title>
		<link>http://jaredheinrichs.com/how-to-use-css-to-reset-the-default-browser-element-settings.html</link>
		<comments>http://jaredheinrichs.com/how-to-use-css-to-reset-the-default-browser-element-settings.html#comments</comments>
		<pubDate>Mon, 01 Feb 2010 06:58:07 +0000</pubDate>
		<dc:creator>Jared Heinrichs</dc:creator>
				<category><![CDATA[CSS]]></category>

		<guid isPermaLink="false">http://jaredheinrichs.com/how-to-use-css-to-reset-the-default-browser-element-settings.html</guid>
		<description><![CDATA[Here is the contents of “reset.css”. I normally link this all my web sites. /* RESET CSS FILE */ html,body,div,span,applet,object,iframe,h1,h2,h3,h4,h5,h6,p,blockquote, pre,a,abbr,acronym,address,big,cite,code,del,dfn,em,font,img,ins,kbd,q,s, samp,small,strike,strong,sub,sup,tt,var,dl,dt,dd,ol,ul,li,fieldset,form,label, legend,table,caption,tbody,tfoot,thead,tr,th,td {border:0;outline:0;vertical-align:middle; background:transparent; margin:0; padding:0;} * {margin:0 padding:0; } a img { border:0 } /* This is called &#8230; <a href="http://jaredheinrichs.com/how-to-use-css-to-reset-the-default-browser-element-settings.html">Continue reading <span class="meta-nav">&#8594;</span></a>]]></description>
			<content:encoded><![CDATA[<p>Here is the contents of “reset.css”. I normally link this all my web sites.</p>
<pre style="border-bottom: #cecece 1px solid; border-left: #cecece 1px solid; padding-bottom: 5px; background-color: #fbfbfb; min-height: 40px; padding-left: 5px; width: 615px; padding-right: 5px; overflow: auto; border-top: #cecece 1px solid; border-right: #cecece 1px solid; padding-top: 5px">
<pre style="background-color: #fbfbfb; margin: 0em; width: 100%; font-family: consolas,&#39;Courier New&#39;,courier,monospace; font-size: 12px"><span style="color: #008000">/* RESET CSS FILE */</span>
</pre>
<pre style="background-color: #fbfbfb; margin: 0em; width: 100%; font-family: consolas,&#39;Courier New&#39;,courier,monospace; font-size: 12px"></pre>
<pre style="background-color: #fbfbfb; margin: 0em; width: 100%; font-family: consolas,&#39;Courier New&#39;,courier,monospace; font-size: 12px"><span style="color: #800000">html</span>,<span style="color: #800000">body</span>,<span style="color: #800000">div</span>,<span style="color: #800000">span</span>,<span style="color: #800000">applet</span>,<span style="color: #800000">object</span>,<span style="color: #800000">iframe</span>,<span style="color: #800000">h1</span>,<span style="color: #800000">h2</span>,<span style="color: #800000">h3</span>,<span style="color: #800000">h4</span>,<span style="color: #800000">h5</span>,<span style="color: #800000">h6</span>,<span style="color: #800000">p</span>,<span style="color: #800000">blockquote</span>,
</pre>
<pre style="background-color: #fbfbfb; margin: 0em; width: 100%; font-family: consolas,&#39;Courier New&#39;,courier,monospace; font-size: 12px"><span style="color: #800000">pre</span>,<span style="color: #800000">a</span>,<span style="color: #800000">abbr</span>,<span style="color: #800000">acronym</span>,<span style="color: #800000">address</span>,<span style="color: #800000">big</span>,<span style="color: #800000">cite</span>,<span style="color: #800000">code</span>,<span style="color: #800000">del</span>,<span style="color: #800000">dfn</span>,<span style="color: #800000">em</span>,<span style="color: #800000">font</span>,<span style="color: #800000">img</span>,<span style="color: #800000">ins</span>,<span style="color: #800000">kbd</span>,<span style="color: #800000">q</span>,<span style="color: #800000">s</span>,
</pre>
<pre style="background-color: #fbfbfb; margin: 0em; width: 100%; font-family: consolas,&#39;Courier New&#39;,courier,monospace; font-size: 12px"><span style="color: #800000">samp</span>,<span style="color: #800000">small</span>,<span style="color: #800000">strike</span>,<span style="color: #800000">strong</span>,<span style="color: #800000">sub</span>,<span style="color: #800000">sup</span>,<span style="color: #800000">tt</span>,<span style="color: #800000">var</span>,<span style="color: #800000">dl</span>,<span style="color: #800000">dt</span>,<span style="color: #800000">dd</span>,<span style="color: #800000">ol</span>,<span style="color: #800000">ul</span>,<span style="color: #800000">li</span>,<span style="color: #800000">fieldset</span>,<span style="color: #800000">form</span>,<span style="color: #800000">label</span>,
</pre>
<pre style="background-color: #fbfbfb; margin: 0em; width: 100%; font-family: consolas,&#39;Courier New&#39;,courier,monospace; font-size: 12px"><span style="color: #800000">legend</span>,<span style="color: #800000">table</span>,<span style="color: #800000">caption</span>,<span style="color: #800000">tbody</span>,<span style="color: #800000">tfoot</span>,<span style="color: #800000">thead</span>,<span style="color: #800000">tr</span>,<span style="color: #800000">th</span>,<span style="color: #800000">td</span>
</pre>
<pre style="background-color: #fbfbfb; margin: 0em; width: 100%; font-family: consolas,&#39;Courier New&#39;,courier,monospace; font-size: 12px">{<span style="color: #ff0000">border</span>:<span style="color: #0000ff">0</span>;<span style="color: #ff0000">outline</span>:<span style="color: #0000ff">0</span>;<span style="color: #ff0000">vertical-align</span>:<span style="color: #0000ff">middle</span>; <span style="color: #ff0000">background</span>:<span style="color: #0000ff">transparent</span>; <span style="color: #ff0000">margin</span>:<span style="color: #0000ff">0</span>; <span style="color: #ff0000">padding</span>:<span style="color: #0000ff">0</span>;}
</pre>
<pre style="background-color: #fbfbfb; margin: 0em; width: 100%; font-family: consolas,&#39;Courier New&#39;,courier,monospace; font-size: 12px"></pre>
<pre style="background-color: #fbfbfb; margin: 0em; width: 100%; font-family: consolas,&#39;Courier New&#39;,courier,monospace; font-size: 12px">* {<span style="color: #ff0000">margin</span>:<span style="color: #0000ff">0 padding:0</span>; }
</pre>
<pre style="background-color: #fbfbfb; margin: 0em; width: 100%; font-family: consolas,&#39;Courier New&#39;,courier,monospace; font-size: 12px"><span style="color: #800000">a</span> <span style="color: #800000">img</span> { <span style="color: #ff0000">border</span>:<span style="color: #0000ff">0 }
</pre>
<pre style="background-color: #fbfbfb; margin: 0em; width: 100%; font-family: consolas,&#39;Courier New&#39;,courier,monospace; font-size: 12px"></pre>
<pre style="background-color: #fbfbfb; margin: 0em; width: 100%; font-family: consolas,&#39;Courier New&#39;,courier,monospace; font-size: 12px">/*
</pre>
<pre style="background-color: #fbfbfb; margin: 0em; width: 100%; font-family: consolas,&#39;Courier New&#39;,courier,monospace; font-size: 12px">This is called the clearfix &quot;hack&quot; to prevent container from colapsing
</pre>
<pre style="background-color: #fbfbfb; margin: 0em; width: 100%; font-family: consolas,&#39;Courier New&#39;,courier,monospace; font-size: 12px">in on itself when all the elements inside are floated elements.
</pre>
<pre style="background-color: #fbfbfb; margin: 0em; width: 100%; font-family: consolas,&#39;Courier New&#39;,courier,monospace; font-size: 12px">Make sure to add --[ class=&quot;container&quot; ]-- to any object that you
</pre>
<pre style="background-color: #fbfbfb; margin: 0em; width: 100%; font-family: consolas,&#39;Courier New&#39;,courier,monospace; font-size: 12px">don't want to colapse.
</pre>
<pre style="background-color: #fbfbfb; margin: 0em; width: 100%; font-family: consolas,&#39;Courier New&#39;,courier,monospace; font-size: 12px">*/
</pre>
<pre style="background-color: #fbfbfb; margin: 0em; width: 100%; font-family: consolas,&#39;Courier New&#39;,courier,monospace; font-size: 12px"></pre>
<pre style="background-color: #fbfbfb; margin: 0em; width: 100%; font-family: consolas,&#39;Courier New&#39;,courier,monospace; font-size: 12px">.container:after {
</pre>
<pre style="background-color: #fbfbfb; margin: 0em; width: 100%; font-family: consolas,&#39;Courier New&#39;,courier,monospace; font-size: 12px">   visibility: hidden</span>; <span style="color: #ff0000">display</span>: <span style="color: #0000ff">block</span>; <span style="color: #ff0000">font-size</span>:<span style="color: #0000ff">0</span>;
</pre>
<pre style="background-color: #fbfbfb; margin: 0em; width: 100%; font-family: consolas,&#39;Courier New&#39;,courier,monospace; font-size: 12px">   <span style="color: #ff0000">content</span>: <span style="color: #0000ff">&quot; &quot;</span>; <span style="color: #ff0000">clear</span>: <span style="color: #0000ff">both</span>; <span style="color: #ff0000">height</span>: <span style="color: #0000ff">0</span>;
</pre>
<pre style="background-color: #fbfbfb; margin: 0em; width: 100%; font-family: consolas,&#39;Courier New&#39;,courier,monospace; font-size: 12px">}
</pre>
<pre style="background-color: #fbfbfb; margin: 0em; width: 100%; font-family: consolas,&#39;Courier New&#39;,courier,monospace; font-size: 12px">
</pre>
<pre style="background-color: #fbfbfb; margin: 0em; width: 100%; font-family: consolas,&#39;Courier New&#39;,courier,monospace; font-size: 12px"><span style="color: #008000">/* start commented backlash hack \*/</span>
</pre>
<pre style="background-color: #fbfbfb; margin: 0em; width: 100%; font-family: consolas,&#39;Courier New&#39;,courier,monospace; font-size: 12px">* <span style="color: #800000">html</span> .<span style="color: #800000">container</span>   {<span style="color: #ff0000">height</span>: <span style="color: #0000ff">1%</span>; }
</pre>
<pre style="background-color: #fbfbfb; margin: 0em; width: 100%; font-family: consolas,&#39;Courier New&#39;,courier,monospace; font-size: 12px">.<span style="color: #800000">container</span>          { <span style="color: #ff0000">display</span>: <span style="color: #0000ff">block</span>; }
</pre>
<pre style="background-color: #fbfbfb; margin: 0em; width: 100%; font-family: consolas,&#39;Courier New&#39;,courier,monospace; font-size: 12px"><span style="color: #008000">/* close commented backlash hack */</span>
</pre>
<pre style="background-color: #fbfbfb; margin: 0em; width: 100%; font-family: consolas,&#39;Courier New&#39;,courier,monospace; font-size: 12px"></pre>
<pre style="background-color: #fbfbfb; margin: 0em; width: 100%; font-family: consolas,&#39;Courier New&#39;,courier,monospace; font-size: 12px"><span style="color: #008000">/* Easy way for me to float items */</span>
</pre>
<pre style="background-color: #fbfbfb; margin: 0em; width: 100%; font-family: consolas,&#39;Courier New&#39;,courier,monospace; font-size: 12px">.<span style="color: #800000">floatleft</span>      { <span style="color: #ff0000">float</span>:<span style="color: #0000ff">left</span>;       }
</pre>
<pre style="background-color: #fbfbfb; margin: 0em; width: 100%; font-family: consolas,&#39;Courier New&#39;,courier,monospace; font-size: 12px">.<span style="color: #800000">floatright</span>     { <span style="color: #ff0000">float</span>:<span style="color: #0000ff">right</span>;      }
</pre>
<pre style="background-color: #fbfbfb; margin: 0em; width: 100%; font-family: consolas,&#39;Courier New&#39;,courier,monospace; font-size: 12px">.<span style="color: #800000">floatmiddle</span>    { <span style="color: #ff0000">margin</span>: <span style="color: #0000ff">0px auto</span>; }</pre>
</pre>
<p>&#160;</p>
<p><font color="#666666" face="Trebuchet MS"></font></p>
]]></content:encoded>
			<wfw:commentRss>http://jaredheinrichs.com/how-to-use-css-to-reset-the-default-browser-element-settings.html/feed</wfw:commentRss>
		<slash:comments>1</slash:comments>
		</item>
		<item>
		<title>How to use firebug to troubleshoot a webpage</title>
		<link>http://jaredheinrichs.com/how-to-use-firebug-to-troubleshoot-a-webpage.html</link>
		<comments>http://jaredheinrichs.com/how-to-use-firebug-to-troubleshoot-a-webpage.html#comments</comments>
		<pubDate>Sun, 10 Jan 2010 23:29:22 +0000</pubDate>
		<dc:creator>Jared Heinrichs</dc:creator>
				<category><![CDATA[CSS]]></category>
		<category><![CDATA[How To]]></category>

		<guid isPermaLink="false">http://jaredheinrichs.com/how-to-use-firebug-to-troubleshoot-a-webpage.html</guid>
		<description><![CDATA[I’ve been wanting to write a tutorial on firebug bet never remember to because when I do remember it’s right after the “emergency” and it’s too late to really take screenshots. I want to thank Chris Coyier for telling people &#8230; <a href="http://jaredheinrichs.com/how-to-use-firebug-to-troubleshoot-a-webpage.html">Continue reading <span class="meta-nav">&#8594;</span></a>]]></description>
			<content:encoded><![CDATA[<p><img style="margin: 0px 15px 0px 0px; display: inline; border-width: 0px;" title="firebug-logo" src="http://jaredheinrichs.com/wp-content/uploads/2010/01/firebuglogo.jpg" border="0" alt="firebug-logo" width="112" height="93" align="left" /> I’ve been wanting to write a tutorial on firebug bet never remember to because when I do remember it’s right after the “emergency” and it’s too late to really take screenshots. I want to thank <a href="http://chriscoyier.net/" target="_blank">Chris Coyier</a> for telling people about this add-on in one of his online videos. If you haven’t checked out his CSS Tricks website I highly recommend it. I also recommend his “<a href="http://digwp.com/book/" target="_blank">Digging Into WordPress Book</a>”.</p>
<h2>What you need</h2>
<p>This should be fairly obvious but you will need to have two things installed on your computer in order to follow along. Please download and install both of these two items.</p>
<ol>
<li><a href="http://www.mozilla.com/en-US/firefox" target="_blank">Download FireFox and install</a></li>
<li><a href="https://addons.mozilla.org/en-US/firefox/addon/1843" target="_blank">Download FireBug and install</a></li>
</ol>
<h2>What is FireBug</h2>
<p>Firebug integrates with Firefox to put a wealth of development tools at your fingertips while you browse. You can edit, debug, and monitor CSS, HTML, and JavaScript live in any web page. Firebug allows you to have a &#8220;live&#8221; online WYSIWYG editor/preview kind of like Dreamweaver. What I mean by &#8220;live&#8221; is Firebug can’t change the code on the website permanently, but it can make the items you are currently viewing move around to give you a sort of preview.</p>
<p>Once you make the changes and find that everything looks good, you still have to edit the file on the server using your favorite program/online editor.</p>
<p>Now I know some of you might be saying &#8221;I have dreamweaver why don&#8217;t I just use that. Make the changes localy and then sync dreamweaver with the server&#8221;.</p>
<p>I would then answer you &#8220;You would be correct if you were working on your OWN site and the files were static HTML.&#8221; Where firebug is a life saver is when you work with online programs like WordPress because programs like Dreamweaver can’t properly show you the output of the PHP scripts on the page.</p>
<h2>How do I run Firebug?</h2>
<p><a href="http://jaredheinrichs.com/wp-content/uploads/2010/01/ToolsMenuFirebug.jpg"><img style="margin: 0px 25px 0px 0px; display: inline; border-width: 0px;" title="Tools-Menu---Firebug" src="http://jaredheinrichs.com/wp-content/uploads/2010/01/ToolsMenuFirebug_thumb.jpg" border="0" alt="Tools-Menu---Firebug" width="58" height="61" align="left" /></a> Glad you asked! You can either just hit your “F12” key while your Firefox program is open or you can go to “Tools” menu and then select “Firebug”.  (Click the Picture to see a more detailed screenshot).</p>
<h2>Now on to the tutorial</h2>
<p>I am probably guessing you have already tried by now running “Firebug” and might feel overwhelmed. If you are, don’t be.</p>
<h2>Why am I going to use Firebug today?</h2>
<p>To put it bluntly when I released my new theme for my website I forgot to code the CSS for the comments section of my blog. I found out about this because I had just released a re-issue of an article about intel’s WiDi Display Technology and John commented on the post and the comment did not look pretty.</p>
<p>Instead of logging into WordPress and figuring out what class I gave the comments section let’s use Firebug to find that out and then play around with the code live to make sure that everything looks the way it should. Once we are happy let’s update WordPress with the CSS we created in Firebug.</p>
<p>Here’s of the shot before the CSS markup was added. (I still can’t believe I missed this before releasing the theme!)</p>
<p><img style="display: block; float: none; margin-left: auto; margin-right: auto; border-width: 0px;" title="image" src="http://jaredheinrichs.com/wp-content/uploads/2010/01/image11.png" border="0" alt="image" width="584" height="106" /></p>
<p>Let’s hit “f12”. Firebug pops up. It should look something like this:</p>
<p><img style="display: block; float: none; margin-left: auto; margin-right: auto; border-width: 0px;" title="image" src="http://jaredheinrichs.com/wp-content/uploads/2010/01/image12.png" border="0" alt="image" width="566" height="255" />I am now go click on the “+” signs and drill down to the section on responses called “commentlist”.</p>
<p><img style="display: inline; border-width: 0px;" title="Firebug---Find-response-area-2" src="http://jaredheinrichs.com/wp-content/uploads/2010/01/FirebugFindresponsearea22.jpg" border="0" alt="Firebug---Find-response-area-2" width="639" height="219" /></p>
<p>Notice when you hover your mouse over the different area’s the selection on the web page will get highlighted?</p>
<p><img style="display: block; float: none; margin-left: auto; margin-right: auto; border-width: 0px;" title="Firebug-Highlighting-code" src="http://jaredheinrichs.com/wp-content/uploads/2010/01/FirebugHighlightingcode2.jpg" border="0" alt="Firebug-Highlighting-code" width="608" height="80" /></p>
<p>To the right of the firebug logo you will see “”HTML”, “CSS” and “Script”. Click on CSS and then the “Edit” button. This will actually let you make changes to the CSS on the fly on effect this one browser session.</p>
<p><img style="display: block; float: none; margin-left: auto; margin-right: auto; border-width: 0px;" title="image" src="http://jaredheinrichs.com/wp-content/uploads/2010/01/image13.png" border="0" alt="image" width="264" height="61" /></p>
<p>In this case I am going to add a few lines of CSS markup to fix the presentation behavior.</p>
<pre style="background-color: #fbfbfb; min-height: 40px; width: 504px; height: 539px; overflow: auto; border: #cecece 1px solid; padding: 5px;">
<pre style="background-color: #fbfbfb; margin: 0em; width: 100%; font-family: consolas,'Courier New',courier,monospace; font-size: 12px;">.<span style="color: #800000;">commentlist</span> {</pre>
<pre style="background-color: #fbfbfb; margin: 0em; width: 100%; font-family: consolas,'Courier New',courier,monospace; font-size: 12px;">	<span style="color: #ff0000;">padding</span>: <span style="color: #0000ff;">0</span>;</pre>
<pre style="background-color: #fbfbfb; margin: 0em; width: 100%; font-family: consolas,'Courier New',courier,monospace; font-size: 12px;">	<span style="color: #ff0000;">text-align</span>: <span style="color: #0000ff;">justify</span>;</pre>
<pre style="background-color: #fbfbfb; margin: 0em; width: 100%; font-family: consolas,'Courier New',courier,monospace; font-size: 12px;">	}</pre>
<pre style="background-color: #fbfbfb; margin: 0em; width: 100%; font-family: consolas,'Courier New',courier,monospace; font-size: 12px;">.<span style="color: #800000;">commentlist</span> <span style="color: #800000;">li</span> {</pre>
<pre style="background-color: #fbfbfb; margin: 0em; width: 100%; font-family: consolas,'Courier New',courier,monospace; font-size: 12px;">	<span style="color: #ff0000;">margin</span>: <span style="color: #0000ff;">15px 0 10px</span>;</pre>
<pre style="background-color: #fbfbfb; margin: 0em; width: 100%; font-family: consolas,'Courier New',courier,monospace; font-size: 12px;">	<span style="color: #ff0000;">padding</span>: <span style="color: #0000ff;">5px 5px 10px 25px</span>;</pre>
<pre style="background-color: #fbfbfb; margin: 0em; width: 100%; font-family: consolas,'Courier New',courier,monospace; font-size: 12px;">	<span style="color: #ff0000;">list-style</span>: <span style="color: #0000ff;">none</span>;</pre>
<pre style="background-color: #fbfbfb; margin: 0em; width: 100%; font-family: consolas,'Courier New',courier,monospace; font-size: 12px;">	}</pre>
<pre style="background-color: #fbfbfb; margin: 0em; width: 100%; font-family: consolas,'Courier New',courier,monospace; font-size: 12px;">.<span style="color: #800000;">commentlist</span> <span style="color: #800000;">li</span> <span style="color: #800000;">ul</span> <span style="color: #800000;">li</span> {</pre>
<pre style="background-color: #fbfbfb; margin: 0em; width: 100%; font-family: consolas,'Courier New',courier,monospace; font-size: 12px;">	<span style="color: #ff0000;">margin-right</span>: <span style="color: #0000ff;">-5px</span>;</pre>
<pre style="background-color: #fbfbfb; margin: 0em; width: 100%; font-family: consolas,'Courier New',courier,monospace; font-size: 12px;">	<span style="color: #ff0000;">margin-left</span>: <span style="color: #0000ff;">10px</span>;</pre>
<pre style="background-color: #fbfbfb; margin: 0em; width: 100%; font-family: consolas,'Courier New',courier,monospace; font-size: 12px;">}</pre>
<pre style="background-color: #fbfbfb; margin: 0em; width: 100%; font-family: consolas,'Courier New',courier,monospace; font-size: 12px;"><span style="color: #800000;">#page</span> <span style="color: #800000;">h3</span>{</pre>
<pre style="background-color: #fbfbfb; margin: 0em; width: 100%; font-family: consolas,'Courier New',courier,monospace; font-size: 12px;">        <span style="color: #800000;">padding</span>: <span style="color: #800000;">5px</span> <span style="color: #800000;">5px</span> <span style="color: #800000;">10px</span> <span style="color: #800000;">15px</span>;</pre>
<pre style="background-color: #fbfbfb; margin: 0em; width: 100%; font-family: consolas,'Courier New',courier,monospace; font-size: 12px;">}</pre>
</pre>
<p>The first 3 entries are for the comment lists and the last one is for the line “One Response to..” header. I know some of you might be saying why didn’t you put the “#page h3” line about the .commentlist items. While I agree it would make finding the “#page h3” item easier again I wanted to show you the order doesn’t really matter in CSS unless there was another item AFTER the tag in question that extended/overwrote the original style.</p>
<p>After entering this code I can see that layout looks much better now that the response is some much further from the edge?</p>
<p><img style="display: block; float: none; margin-left: auto; margin-right: auto; border-width: 0px;" title="image" src="http://jaredheinrichs.com/wp-content/uploads/2010/01/image14.png" border="0" alt="image" width="527" height="149" /></p>
<p>Hope this helps give you introductory to Firebug and some of it’s unique abilities!</p>
]]></content:encoded>
			<wfw:commentRss>http://jaredheinrichs.com/how-to-use-firebug-to-troubleshoot-a-webpage.html/feed</wfw:commentRss>
		<slash:comments>1</slash:comments>
		</item>
		<item>
		<title>CSS Type properties cheat sheet</title>
		<link>http://jaredheinrichs.com/css-type-properties-cheat-sheet.html</link>
		<comments>http://jaredheinrichs.com/css-type-properties-cheat-sheet.html#comments</comments>
		<pubDate>Mon, 31 Aug 2009 14:09:58 +0000</pubDate>
		<dc:creator>Jared Heinrichs</dc:creator>
				<category><![CDATA[CSS]]></category>

		<guid isPermaLink="false">http://jaredheinrichs.com/css-type-properties-cheat-sheet.html</guid>
		<description><![CDATA[This post is going to be going over all the Type CSS Properties and giving you the properties of each item. Since I like Adobe Dreamweaver’s GUI so much I will use a screen shot of it as a reference &#8230; <a href="http://jaredheinrichs.com/css-type-properties-cheat-sheet.html">Continue reading <span class="meta-nav">&#8594;</span></a>]]></description>
			<content:encoded><![CDATA[<p>This post is going to be going over all the Type CSS Properties and giving you the properties of each item. Since I like Adobe Dreamweaver’s GUI so much I will use a screen shot of it as a reference because it provides a clean and compact way of organizing the properties.</p>
<p> <span id="more-1524"></span><br />
<h3><a href="http://jaredheinrichs.com/wp-content/uploads/2009/08/image41.png"><img style="border-right-width: 0px; display: inline; border-top-width: 0px; border-bottom-width: 0px; border-left-width: 0px" title="image" border="0" alt="image" src="http://jaredheinrichs.com/wp-content/uploads/2009/08/image_thumb39.png" width="573" height="422" /></a> </h3>
<p><strong></strong></p>
<p><strong>CSS Font Families</strong></p>
<div class="csharpcode">
<pre><span class="lnum">   1:  </span>font-family: Verdana, Geneva, sans-serif;</pre>
<pre><span class="lnum">   2:  </span>font-family: Georgia, &quot;Times New Roman&quot;, Times, serif;</pre>
<pre><span class="lnum">   3:  </span>font-family: &quot;Courier New&quot;, Courier, monospace;</pre>
<pre><span class="lnum">   4:  </span>font-family: Arial, Helvetica, sans-serif;</pre>
<pre><span class="lnum">   5:  </span>font-family: Tahoma, Geneva, sans-serif;</pre>
<pre><span class="lnum">   6:  </span>font-family: &quot;Trebuchet MS&quot;, Arial, Helvetica, sans-serif;</pre>
<pre><span class="lnum">   7:  </span>font-family: &quot;Arial Black&quot;, Gadget, sans-serif;</pre>
<pre><span class="lnum">   8:  </span>font-family: &quot;Times New Roman&quot;, Times, serif;</pre>
<pre><span class="lnum">   9:  </span>font-family: &quot;Palatino Linotype&quot;, &quot;Book Antiqua&quot;, Palatino, serif;</pre>
<pre><span class="lnum">  10:  </span>font-family: &quot;Lucida Sans Unicode&quot;, &quot;Lucida Grande&quot;, sans-serif;</pre>
<pre><span class="lnum">  11:  </span>font-family: &quot;MS Serif&quot;, &quot;New York&quot;, serif;</pre>
<pre><span class="lnum">  12:  </span>font-family: &quot;Lucida Console&quot;, Monaco, monospace;</pre>
<pre><span class="lnum">  13:  </span>font-family: &quot;Comic Sans MS&quot;, cursive;</pre>
</div>
<style type="text/css">
<p>.csharpcode, .csharpcode pre
{
	font-size: small;
	color: black;
	font-family: consolas, "Courier New", courier, monospace;
	background-color: #ffffff;
	/*white-space: pre;*/
}
.csharpcode pre { margin: 0em; }
.csharpcode .rem { color: #008000; }
.csharpcode .kwrd { color: #0000ff; }
.csharpcode .str { color: #006080; }
.csharpcode .op { color: #0000c0; }
.csharpcode .preproc { color: #cc6633; }
.csharpcode .asp { background-color: #ffff00; }
.csharpcode .html { color: #800000; }
.csharpcode .attr { color: #ff0000; }
.csharpcode .alt 
{
	background-color: #f4f4f4;
	width: 100%;
	margin: 0em;
}
.csharpcode .lnum { color: #606060; }</style>
<p><strong></strong></p>
<p><strong>CSS Font Size:</strong></p>
<div class="csharpcode">
<pre><span class="lnum">   1:  </span>font-size: 12px;</pre>
<pre><span class="lnum">   2:  </span>font-size: 12em;</pre>
</div>
<p><strong></strong></p>
<p><strong>CSS Font Weight</strong></p>
<div class="csharpcode">
<pre><span class="lnum">   1:  </span>font-weight: normal;</pre>
<pre><span class="lnum">   2:  </span>font-weight: bold;</pre>
<pre><span class="lnum">   3:  </span>font-weight: bolder;</pre>
<pre><span class="lnum">   4:  </span>font-weight: lighter;</pre>
</div>
<p><strong></strong></p>
<p><strong>CSS Font Style</strong></p>
<div class="csharpcode">
<pre><span class="lnum">   1:  </span>font-style: normal;</pre>
<pre><span class="lnum">   2:  </span>font-style: italic;</pre>
<pre><span class="lnum">   3:  </span>font-style: oblique;</pre>
</div>
<div class="csharpcode">
<pre><span class="lnum">   1:  </span>font-variant: normal;</pre>
<pre><span class="lnum">   2:  </span>font-variant: small-caps;</pre>
</div>
<p><strong></strong></p>
<p><strong>CSS Line Height</strong></p>
<div class="csharpcode">
<pre><span class="lnum">   1:  </span>line-height: normal;</pre>
<pre><span class="lnum">   2:  </span>line-height: 12px;</pre>
<pre><span class="lnum">   3:  </span>line-height: 12em;</pre>
</div>
<p><strong></strong></p>
<p><strong>CSS Text Transform</strong></p>
<div class="csharpcode">
<pre><span class="lnum">   1:  </span>text-transform: capitalize;</pre>
<pre><span class="lnum">   2:  </span>text-transform: uppercase;</pre>
<pre><span class="lnum">   3:  </span>text-transform: lowercase;</pre>
<pre><span class="lnum">   4:  </span>text-transform: none;</pre>
</div>
<p><strong></strong></p>
<p><strong>CSS Text Decoration</strong></p>
<div class="csharpcode">
<pre><span class="lnum">   1:  </span>text-decoration: underline; </pre>
<pre><span class="lnum">   2:  </span>text-decoration: overline;</pre>
<pre><span class="lnum">   3:  </span>text-decoration: line-through;</pre>
<pre><span class="lnum">   4:  </span>text-decoration: blink;</pre>
<pre><span class="lnum">   5:  </span>text-decoration: none;</pre>
</div>
<p><strong></strong></p>
<p><strong>CSS Text Color</strong></p>
<div class="csharpcode">
<pre><span class="lnum">   1:  </span>color: #000; /* Black */</pre>
<pre><span class="lnum">   2:  </span>color: #FFF; /* White */</pre>
</div>
<p><strong></strong></p>
<p><strong>CSS Example for &lt;p&gt;</strong></p>
<div class="csharpcode">
<pre><span class="lnum">   1:  </span>p</pre>
<pre><span class="lnum">   2:  </span>{</pre>
<pre><span class="lnum">   3:  </span>    color: #000; <span class="rem">/* White */</span></pre>
<pre><span class="lnum">   4:  </span>    font-family: <span class="str">&quot;Arial Black&quot;</span>, <span class="str">&quot;Gadget&quot;</span>, <span class="str">&quot;sans-serif&quot;</span>;</pre>
<pre><span class="lnum">   5:  </span>    font-size: 12px;</pre>
<pre><span class="lnum">   6:  </span>    font-style: normal;</pre>
<pre><span class="lnum">   7:  </span>    line-height: normal;</pre>
<pre><span class="lnum">   8:  </span>    font-weight: normal;</pre>
<pre><span class="lnum">   9:  </span>    font-variant: normal;    </pre>
<pre><span class="lnum">  10:  </span>}</pre>
</div>
<style type="text/css">
<p>.csharpcode, .csharpcode pre
{
	font-size: small;
	color: black;
	font-family: consolas, "Courier New", courier, monospace;
	background-color: #ffffff;
	/*white-space: pre;*/
}
.csharpcode pre { margin: 0em; }
.csharpcode .rem { color: #008000; }
.csharpcode .kwrd { color: #0000ff; }
.csharpcode .str { color: #006080; }
.csharpcode .op { color: #0000c0; }
.csharpcode .preproc { color: #cc6633; }
.csharpcode .asp { background-color: #ffff00; }
.csharpcode .html { color: #800000; }
.csharpcode .attr { color: #ff0000; }
.csharpcode .alt 
{
	background-color: #f4f4f4;
	width: 100%;
	margin: 0em;
}
.csharpcode .lnum { color: #606060; }</style>
]]></content:encoded>
			<wfw:commentRss>http://jaredheinrichs.com/css-type-properties-cheat-sheet.html/feed</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
	</channel>
</rss>

