<?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>Kaffehausdekadenzmoderne &#187; html</title>
	<atom:link href="http://sugardew.com/blog/tag/html/feed/" rel="self" type="application/rss+xml" />
	<link>http://sugardew.com/blog</link>
	<description></description>
	<lastBuildDate>Tue, 06 Jul 2010 00:07:55 +0000</lastBuildDate>
	<generator>http://wordpress.org/?v=2.8.2</generator>
	<language>en</language>
	<sy:updatePeriod>hourly</sy:updatePeriod>
	<sy:updateFrequency>1</sy:updateFrequency>
			<item>
		<title>Floats vs. Absolute Positioning</title>
		<link>http://sugardew.com/blog/2009/10/floats-vs-absolute-positioning/</link>
		<comments>http://sugardew.com/blog/2009/10/floats-vs-absolute-positioning/#comments</comments>
		<pubDate>Thu, 29 Oct 2009 04:22:41 +0000</pubDate>
		<dc:creator>t!na</dc:creator>
				<category><![CDATA[code]]></category>
		<category><![CDATA[css]]></category>
		<category><![CDATA[html]]></category>
		<category><![CDATA[the_internets]]></category>
		<category><![CDATA[webdesign]]></category>

		<guid isPermaLink="false">http://sugardew.com/blog/?p=496</guid>
		<description><![CDATA[For a long time, I&#8217;ve gone away from using absolute positioning to structure my webpages and have since relied almost exclusively on floats to position things side-by-side. It seemed that absolute positioning had its disadvantages because it takes elements out of the flow of the page. So if you absolutely position a long block of [...]]]></description>
			<content:encoded><![CDATA[<p>For a long time, I&#8217;ve gone away from using absolute positioning to structure my webpages and have since relied almost exclusively on floats to position things side-by-side. It seemed that absolute positioning had its disadvantages because it takes elements out of the flow of the page. So if you absolutely position a long block of text or something likewise huge, it can cover and obscure small inline things that follow it. It just makes everything a little bit crazy because suddenly things aren&#8217;t stacking up the way you expect, you get z-index issues, and IE6 explodes (IE6 explodes no matter what you do, actually.). But just now I realized one benefit of using absolute positioning over floats in some places: looking good when <a href="http://naked.dustindiaz.com/" target="_blank">naked</a>.</p>
<p><span id="more-496"></span>(Why is it important to look good naked? Well&#8230;you never know who might be using Links&#8230; cough cough)</p>
<p>With floats, you have to be sensitive to where elements are placed in the flow of your code. The element being floated always has to precede the element it floats around. This can weirdify your naked site (and your code) if, for one example, you have the following 2-column situation:</p>
<p><img class="aligncenter size-full wp-image-499" title="weird_layout" src="http://sugardew.com/blog/wp-content/uploads/2009/10/weird_layout.gif" alt="weird_layout" width="400" height="300" /></p>
<p>If you were to use floats to throw the nav to the left like that, the code for the nav would have to come first in the code sequence. This would be akin to a book where the table of contents is on the cover, and the title is on the inside first page.</p>
<p>In this one website I&#8217;m currently coding, there&#8217;s even more weirdness because I designed it in a kind of unusual way. I didn&#8217;t even realize just how unusual it was until I started coding it. Anyway, most of what you&#8217;d normally consider the &#8220;header&#8221; is actually vertical and on the left of the content, and the main nav is to the far left of the &#8220;header.&#8221; There is also a separate text part of the title that appears above the content, but still next to the header. Finally there&#8217;s a Quick Links bar at the very very top. (Link soon&#8230; It&#8217;ll explain better.) Without absolute positioning, this could be disastrous. The order of the code would have to be something like:</p>
<ul>
<li>Quick Links</li>
<li>(little decorative animation)</li>
<li>Menu</li>
<li>Header</li>
<li>Header Title</li>
<li>Content</li>
</ul>
<p>Stripped of CSS, the page wouldn&#8217;t even say the title of the website until halfway down the page. Hardly ideal.</p>
<p>But if you absolute position, you can rearrange it to something that makes more sense because absolute positioning doesn&#8217;t care about order. You can position something at the top of the page even if it comes last in the code. So instead of the above, I could do something like:</p>
<ul>
<li>Header</li>
<li>Header Title</li>
<li>Quick Links</li>
<li>(little decorative animation)</li>
<li>Menu</li>
<li>Content</li>
</ul>
<p>&#8230; which, sans CSS, results in a site that looks like it was made in 1995, but still makes a lot more sense than the version above.</p>
<p>I think, in general, I am liable to stick with floats for all but the impossibly weird layouts that I&#8217;ve made. Floats just seem to make more sense to me because they are more fluid and flexible, shifting up and down the page according to the size of the content. Absolute positioning is&#8230; well, absolute. It always stays in one spot no matter what. It definitely should not be used for images accompanying text, for example, unless you are a masochist. Another good thing about floats is that they stretch out containing elements if you put a clear right below the float (and still inside the containing element). This is useful for backgrounds that go behind the full length of the floated element. Impossible with absolute position, unless, again, you are a masochist and like calculating numbers with Javascript.</p>
<p>But if semantics are at stake, then it&#8217;s better to throw in some absolute positioning to supplement the basic floated structure.</p>
<p>Every site one codes is a little different, so it depends totally on the situation. I learnt this the hard way—before, I thought you only needed to learn how to code a website once and then you could code any site out there. I was&#8230; wrong to say the least. Anyway, this is kind of fun in its own way&#8230; solving the puzzle of HTML in such a way so that all users can be as happy as can be. Yippee.</p>
]]></content:encoded>
			<wfw:commentRss>http://sugardew.com/blog/2009/10/floats-vs-absolute-positioning/feed/</wfw:commentRss>
		<slash:comments>2</slash:comments>
		</item>
		<item>
		<title>&#8220;Fun&#8221; with HTML Emails</title>
		<link>http://sugardew.com/blog/2009/03/fun-with-html-emails/</link>
		<comments>http://sugardew.com/blog/2009/03/fun-with-html-emails/#comments</comments>
		<pubDate>Tue, 17 Mar 2009 16:13:56 +0000</pubDate>
		<dc:creator>t!na</dc:creator>
				<category><![CDATA[code]]></category>
		<category><![CDATA[email]]></category>
		<category><![CDATA[html]]></category>
		<category><![CDATA[technology]]></category>
		<category><![CDATA[web]]></category>

		<guid isPermaLink="false">http://sugardew.com/blog/?p=114</guid>
		<description><![CDATA[Just wanted to write a quick post to link some articles for future reference.
Writing an HTML email is like taking a regressive leap 10 years into the past. Mangled, reinterpreted markup; wildly inconsistent rendering; table layouts and font tags everywhere. Aeiieeeee!
But in case you need to dive into this mayhem, here&#8217;s how you&#8217;d do it:

Writing [...]]]></description>
			<content:encoded><![CDATA[<p>Just wanted to write a quick post to link some articles for future reference.</p>
<p>Writing an HTML email is like taking a regressive leap 10 years into the past. Mangled, reinterpreted markup; wildly inconsistent rendering; table layouts and font tags everywhere. Aeiieeeee!</p>
<p>But in case you need to dive into this mayhem, here&#8217;s how you&#8217;d do it:</p>
<ul>
<li><a title="Permanent Link to Writing cross-client HTML email" rel="bookmark" href="http://emtek.net.nz/blog/2008/08/28/writing-cross-client-html-email/" target="_blank">Writing cross-client HTML email</a> &#8211; emtek.net.nz<a title="Permanent Link to Writing cross-client HTML email" rel="bookmark" href="http://emtek.net.nz/blog/2008/08/28/writing-cross-client-html-email/" target="_blank"><br />
</a></li>
<li><a href="http://www.campaignmonitor.com/design-guidelines/" target="_blank">Email Design Guidelines</a> &#8211; CampaignMonitor.com</li>
<li><a href="http://www.campaignmonitor.com/css/" target="_blank">CSS Support in Email (2008)</a> &#8211; CampaignMonitor.com</li>
<li><a href="http://www.campaignmonitor.com/videoinemail/" target="_blank">Video in Email</a> &#8211; CampaignMonitor.com (long story short: you can&#8217;t do it)</li>
</ul>
]]></content:encoded>
			<wfw:commentRss>http://sugardew.com/blog/2009/03/fun-with-html-emails/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
	</channel>
</rss>
