<?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>sentient beings &#187; CSS</title>
	<atom:link href="http://www.sentientbeings.com/category/css/feed/" rel="self" type="application/rss+xml" />
	<link>http://www.sentientbeings.com</link>
	<description>Just another WordPress weblog</description>
	<lastBuildDate>Sun, 06 Jun 2010 08:22:23 +0000</lastBuildDate>
	<generator>http://wordpress.org/?v=2.8</generator>
	<language>en</language>
	<sy:updatePeriod>hourly</sy:updatePeriod>
	<sy:updateFrequency>1</sy:updateFrequency>
	<xhtml:meta xmlns:xhtml="http://www.w3.org/1999/xhtml" name="robots" content="noindex" />
		<item>
		<title>Moving from &lt;table&gt;s to &lt;div&gt;s</title>
		<link>http://www.sentientbeings.com/2009/01/moving-from-tables-to-divs/</link>
		<comments>http://www.sentientbeings.com/2009/01/moving-from-tables-to-divs/#comments</comments>
		<pubDate>Mon, 26 Jan 2009 15:55:59 +0000</pubDate>
		<dc:creator>Kristof</dc:creator>
				<category><![CDATA[CSS]]></category>
		<category><![CDATA[HTML]]></category>

		<guid isPermaLink="false">http://www.sentientbeings.com/?p=75</guid>
		<description><![CDATA[The title is actually misleading. I'll be explaining how to ditch tables and move to a more CSS-centered approach of your website.
There is still a large number of webdesigners and webdevelopers that use tables over divs and CSS to design their website. This article is meant as a "getting started" tutorial to help you move [...]]]></description>
			<content:encoded><![CDATA[<p>The title is actually misleading. I'll be explaining how to ditch tables and move to a more CSS-centered approach of your website.</p>
<p>There is still a large number of webdesigners and webdevelopers that use tables over divs and CSS to design their website. This article is meant as a "getting started" tutorial to help you move from tables to divs.</p>
<p>This is in no way a complete guide to CSS-centered design, and it certainly doesn't explain about all the niceties of CSS-centered design. It's meant to help people move away from tables and start appreciating CSS-centered design.</p>
<p><span id="more-75"></span></p>
<p><strong>Using a doctype</strong></p>
<p>The first thing you want is a doctype. More specifically, you'll want a STRICT doctype. Most of the problems people encounter at first when using divs instead of tables arise from using transitional doctypes. Strict doctypes will make sure that all browsers look upon your CSS in more or less the same way - you eliminate a lot of the margin/padding/alignment problems by using STRICT doctypes. Use the following at the very top of your documents.</p>
<blockquote><p>&lt;!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd"&gt;</p></blockquote>
<p>Yes, you can use 1.1 if you prefer. It's even better, since there is no confusion between strict, transitional or framesets in this XHTML standard.</p>
<blockquote><p>&lt;!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.1//EN" "http://www.w3.org/TR/xhtml11/DTD/xhtml11.dtd"&gt;</p></blockquote>
<p><strong>Designing for Divs</strong></p>
<p>Being a good webdesigner doesn't just mean coming up with fancy graphics. Being a good webdesigner also means knowing the limitations of (X)HTML, CSS and keeping those in mind when designing. To make your life easier, here are a few rules of thumb.</p>
<ul>
<li>Separate the header from the content from the navigation from the footer from the disclaimer from the sidebar. That doesn't mean your layout has to be columnar or in blocks - it just means that you should see the HTML while designing the page. Know where the different sections of your website will be and layout accordingly;</li>
<li>Use elaborate CSS where possible to substitute for images;</li>
<li>Use background images where possible to substitute for elaborate and complex HTML;</li>
</ul>
<p><strong>Centering your web layout</strong></p>
<p>Instead of using a master table and setting the width to 100% and then fitting the actual table with your design, you can use the following the autocenter your web layout.</p>
<p>Consider the following HTML content.</p>
<pre>&lt;body&gt;
&lt;div id="wrapper"&gt;This div will be perfectly centered.&lt;/div&gt;
&lt;/body&gt;</pre>
<p>Pair the HTML content with the CSS below.</p>
<pre>body, html
{
     margin: auto;
}

#wrapper
{
     margin: auto;
}</pre>
<p>Setting the margin to "auto" will make sure your browsers autocenters the layout by calculating the left and right margins necessary to center the layout.</p>
<p><strong>The Wrapper</strong></p>
<p>The <em>wrapper</em> div is a container that you set to the width you want your website to have. It's the box that you'll be working in. You can omit this if you want your website to be "fullscreen".</p>
<p><strong>Creating columnar layout</strong></p>
<p>Creating columnar layout is simple. Use <em>float</em> to make certain DIVs align left or right, automatically. Give them a width to work with and you're set. Use <em>clear</em> to clear to reset the alignment.</p>
<p>Consider the following HTML content.</p>
<pre>&lt;body&gt;
     &lt;div id="wrapper"&gt;
          &lt;div id="columnleft"&gt;This is the left column&lt;/div&gt;
          &lt;div id="columnright"&gt;This is the right column&lt;/div&gt;
     &lt;/div&gt;
&lt;/body&gt;</pre>
<p>There are several ways to make the left column align left and the right column align right. The method you choose is based on what column you want to have priority. The column you want to have priority should be declared first. The <em>float</em> property you need is the result of this decision. If you want the RIGHT column to have priority, then you first declare the RIGHT column and then set the <em>float</em> property to RIGHT.</p>
<pre>&lt;body&gt;
     &lt;div id="wrapper"&gt;
          &lt;div id="columnright" style="float: right;"&gt;This is the right column&lt;/div&gt;
          &lt;div id="columnleft"This is the left column&lt;/div&gt;
     &lt;/div&gt;
&lt;/body&gt;</pre>
<div>
<p>Vice versa, you first declare the LEFT column if you want to do so, then set <em>float</em> to LEFT.</p>
<pre>&lt;body&gt;
     &lt;div id="wrapper"&gt;
          &lt;div id="columnleft" style="float: left;"&gt;This is the left column&lt;/div&gt;
          &lt;div id="columnright"&gt;This is the right column&lt;/div&gt;
     &lt;/div&gt;
&lt;/body&gt;</pre>
<p>Problem is: if one of both columns is shorter than the other, the longest column will start to take up to the space left by the shorter column. To avoid this, give the suspected longest column a width. If you want to stop floating divs, use the "clear" property and then either <em>left</em>, <em>right </em>or <em>both</em>.</p>
<pre>&lt;body&gt;
     &lt;div id="wrapper"&gt;
          &lt;div id="columnleft" style="float: left;"&gt;This is the left column&lt;/div&gt;
          &lt;div id="columnright"&gt;This is the right column&lt;/div&gt;
     &lt;/div&gt;
     &lt;div style="clear:both"&gt;This will reset to the full width of your wrapper. Ideal for a footer, for example.&lt;/div&gt;
&lt;/body&gt;</pre>
<p>You can also use &lt;br clear="all" /&gt; but that's not the nicest way to clear your floats.</p></div>
<p><strong>Questions?</strong></p>
<p><strong></strong>Questions? Post them in the comments and I'll answer them. Most of them. At least the ones pertaining to CSS and/or this article.</p>


<!-- Begin TwitThis script (http://twitthis.com/) -->
<div class="twitThis">
<script type="text/javascript" src="http://s3.chuug.com/chuug.twitthis.scripts/twitthis.js"></script>
<script type="text/javascript">
<!--
document.write('<a href="javascript:;" onclick="TwitThis.pop();"><img src="http://i14.photobucket.com/albums/a318/intGod/Blog/twitter_icons_24.png" alt="Tweet this"></a>');
//-->
</script>
</div>
<!-- /End -->

<!-- Social Bookmarks BEGIN -->
<div class="social_bookmark">
<a><strong><em><hr></em></strong></a>
<br />
<div class="d">
<br />
<a onclick="window.open(this.href, '_blank', 'scrollbars=yes,menubar=no,height=600,width=750,resizable=yes,toolbar=no,location=no,status=no'); return false;" href="http://del.icio.us/post?url=http://www.sentientbeings.com/2009/01/moving-from-tables-to-divs/&amp;title=Moving+from+%26lt%3Btable%26gt%3Bs+to+%26lt%3Bdiv%26gt%3Bs" rel="nofollow" title="Add to&nbsp;Del.icio.us"><img class="social_img" src="http://www.sentientbeings.com/wp-content/plugins/social-bookmarks/images/delicious.png" title="Add to&nbsp;Del.icio.us" alt="Add to&nbsp;Del.icio.us" /></a>
<a onclick="window.open(this.href, '_blank', 'scrollbars=yes,menubar=no,height=600,width=750,resizable=yes,toolbar=no,location=no,status=no'); return false;" href="http://digg.com/submit?phase=2&amp;url=http://www.sentientbeings.com/2009/01/moving-from-tables-to-divs/&amp;title=Moving+from+%26lt%3Btable%26gt%3Bs+to+%26lt%3Bdiv%26gt%3Bs" rel="nofollow" title="Add to&nbsp;digg"><img class="social_img" src="http://www.sentientbeings.com/wp-content/plugins/social-bookmarks/images/digg.png" title="Add to&nbsp;digg" alt="Add to&nbsp;digg" /></a>
<a onclick="window.open(this.href, '_blank', 'scrollbars=yes,menubar=no,height=600,width=750,resizable=yes,toolbar=no,location=no,status=no'); return false;" href="http://www.google.com/bookmarks/mark?op=edit&amp;output=popup&amp;bkmk=http://www.sentientbeings.com/2009/01/moving-from-tables-to-divs/&amp;title=Moving+from+%26lt%3Btable%26gt%3Bs+to+%26lt%3Bdiv%26gt%3Bs" rel="nofollow" title="Add to&nbsp;Google Bookmarks"><img class="social_img" src="http://www.sentientbeings.com/wp-content/plugins/social-bookmarks/images/google.png" title="Add to&nbsp;Google Bookmarks" alt="Add to&nbsp;Google Bookmarks" /></a>
<a onclick="window.open(this.href, '_blank', 'scrollbars=yes,menubar=no,height=600,width=750,resizable=yes,toolbar=no,location=no,status=no'); return false;" href="http://reddit.com/submit?url=http://www.sentientbeings.com/2009/01/moving-from-tables-to-divs/&amp;title=Moving+from+%26lt%3Btable%26gt%3Bs+to+%26lt%3Bdiv%26gt%3Bs" rel="nofollow" title="Add to&nbsp;reddit"><img class="social_img" src="http://www.sentientbeings.com/wp-content/plugins/social-bookmarks/images/reddit.png" title="Add to&nbsp;reddit" alt="Add to&nbsp;reddit" /></a>
<a onclick="window.open(this.href, '_blank', 'scrollbars=yes,menubar=no,height=600,width=750,resizable=yes,toolbar=no,location=no,status=no'); return false;" href="http://slashdot.org/bookmark.pl?url=http://www.sentientbeings.com/2009/01/moving-from-tables-to-divs/&amp;title=Moving+from+%26lt%3Btable%26gt%3Bs+to+%26lt%3Bdiv%26gt%3Bs" rel="nofollow" title="Add to&nbsp;Slashdot"><img class="social_img" src="http://www.sentientbeings.com/wp-content/plugins/social-bookmarks/images/slashdot.png" title="Add to&nbsp;Slashdot" alt="Add to&nbsp;Slashdot" /></a>
<a onclick="window.open(this.href, '_blank', 'scrollbars=yes,menubar=no,height=600,width=750,resizable=yes,toolbar=no,location=no,status=no'); return false;" href="http://www.stumbleupon.com/submit.php?url=http://www.sentientbeings.com/2009/01/moving-from-tables-to-divs/&amp;title=Moving+from+%26lt%3Btable%26gt%3Bs+to+%26lt%3Bdiv%26gt%3Bs" rel="nofollow" title="Add to&nbsp;Stumble Upon"><img class="social_img" src="http://www.sentientbeings.com/wp-content/plugins/social-bookmarks/images/stumbleupon.png" title="Add to&nbsp;Stumble Upon" alt="Add to&nbsp;Stumble Upon" /></a>
<a onclick="window.open(this.href, '_blank', 'scrollbars=yes,menubar=no,height=600,width=750,resizable=yes,toolbar=no,location=no,status=no'); return false;" href="http://www.technorati.com/faves?add=http://www.sentientbeings.com/2009/01/moving-from-tables-to-divs/" rel="nofollow" title="Add to&nbsp;Technorati"><img class="social_img" src="http://www.sentientbeings.com/wp-content/plugins/social-bookmarks/images/technorati.png" title="Add to&nbsp;Technorati" alt="Add to&nbsp;Technorati" /></a>
<a onclick="window.open(this.href, '_blank', 'scrollbars=yes,menubar=no,height=600,width=750,resizable=yes,toolbar=no,location=no,status=no'); return false;" href="http://myweb2.search.yahoo.com/myresults/bookmarklet?u=http://www.sentientbeings.com/2009/01/moving-from-tables-to-divs/&amp;t=Moving+from+%26lt%3Btable%26gt%3Bs+to+%26lt%3Bdiv%26gt%3Bs" rel="nofollow" title="Add to&nbsp;Yahoo My Web"><img class="social_img" src="http://www.sentientbeings.com/wp-content/plugins/social-bookmarks/images/yahoo.png" title="Add to&nbsp;Yahoo My Web" alt="Add to&nbsp;Yahoo My Web" /></a>
<br />
</div>
</div>
<!-- Social Bookmarks END -->
]]></content:encoded>
			<wfw:commentRss>http://www.sentientbeings.com/2009/01/moving-from-tables-to-divs/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>riajobs.org</title>
		<link>http://www.sentientbeings.com/2008/06/riajobsorg/</link>
		<comments>http://www.sentientbeings.com/2008/06/riajobsorg/#comments</comments>
		<pubDate>Fri, 27 Jun 2008 05:43:32 +0000</pubDate>
		<dc:creator>Kristof</dc:creator>
				<category><![CDATA[Air]]></category>
		<category><![CDATA[CSS]]></category>
		<category><![CDATA[Flash]]></category>
		<category><![CDATA[HTML]]></category>
		<category><![CDATA[Selfish]]></category>
		<category><![CDATA[Silverlight]]></category>

		<guid isPermaLink="false">http://www.sentientbeings.com/?p=18</guid>
		<description><![CDATA[Peter Elst just launched riajobs.org. Riajobs.org is a community-based jobboard. Amazingly enough, the site is free - even for companies that want to post jobs. There's of course the odd feature that requires a fee but even then, 20 percent of the monthly revenue will be donated to charity.

As I write this entry, jobs are [...]]]></description>
			<content:encoded><![CDATA[<p><a href="http://www.peterelst.com/blog/2008/06/27/riajobsorg-launched/">Peter Elst just launched riajobs.org</a>. <a href="http://riajobs.org">Riajobs.org</a> is a community-based jobboard. Amazingly enough, the site is free - even for companies that want to post jobs. There's of course the odd feature that requires a fee but even then, 20 percent of the monthly revenue will be donated to charity.</p>
<p style="text-align: center;"><a href="http://riajobs.org"><img class="aligncenter" src="http://i14.photobucket.com/albums/a318/intGod/Blog/riajobs-blog.jpg" alt="" /></a></p>
<p>As I write this entry, jobs are being added to the site. The few jobs currently posted originate from all over the globe. Community support looks strong and will be a major success factor for riajobs.org.</p>
<p>The only thing this site needs is a little space for potential candidates and freelancers to leave an impression and the matchmaking site will be complete. And whaddayaknow? Peter already added that to the list of features to be added "in the near future".</p>
<p>Let's hope riajobs.org is not going to turn into another "enter ALL of your details including highschool friends and that female teacher you had a crush on and all the different types of pasta you've eaten in your life and all of the places you visited"  setup, but, instead, a simple 1-minute setup. I've always felt that careersites asked way too much information. Just the basics and company and candidate will sort things out themselves, thank you very much.</p>
<p>I believe "niche" websites like this will become the ultimate future. A small company in the Netherlands has set-up a jobsite aimed solely at the creative industry and it's becoming increasingly popular as well.</p>
<p>Let's root for riajobs.org! From the community, for the community and, eventually, by the community.</p>


<!-- Begin TwitThis script (http://twitthis.com/) -->
<div class="twitThis">
<script type="text/javascript" src="http://s3.chuug.com/chuug.twitthis.scripts/twitthis.js"></script>
<script type="text/javascript">
<!--
document.write('<a href="javascript:;" onclick="TwitThis.pop();"><img src="http://i14.photobucket.com/albums/a318/intGod/Blog/twitter_icons_24.png" alt="Tweet this"></a>');
//-->
</script>
</div>
<!-- /End -->

<!-- Social Bookmarks BEGIN -->
<div class="social_bookmark">
<a><strong><em><hr></em></strong></a>
<br />
<div class="d">
<br />
<a onclick="window.open(this.href, '_blank', 'scrollbars=yes,menubar=no,height=600,width=750,resizable=yes,toolbar=no,location=no,status=no'); return false;" href="http://del.icio.us/post?url=http://www.sentientbeings.com/2008/06/riajobsorg/&amp;title=riajobs.org" rel="nofollow" title="Add to&nbsp;Del.icio.us"><img class="social_img" src="http://www.sentientbeings.com/wp-content/plugins/social-bookmarks/images/delicious.png" title="Add to&nbsp;Del.icio.us" alt="Add to&nbsp;Del.icio.us" /></a>
<a onclick="window.open(this.href, '_blank', 'scrollbars=yes,menubar=no,height=600,width=750,resizable=yes,toolbar=no,location=no,status=no'); return false;" href="http://digg.com/submit?phase=2&amp;url=http://www.sentientbeings.com/2008/06/riajobsorg/&amp;title=riajobs.org" rel="nofollow" title="Add to&nbsp;digg"><img class="social_img" src="http://www.sentientbeings.com/wp-content/plugins/social-bookmarks/images/digg.png" title="Add to&nbsp;digg" alt="Add to&nbsp;digg" /></a>
<a onclick="window.open(this.href, '_blank', 'scrollbars=yes,menubar=no,height=600,width=750,resizable=yes,toolbar=no,location=no,status=no'); return false;" href="http://www.google.com/bookmarks/mark?op=edit&amp;output=popup&amp;bkmk=http://www.sentientbeings.com/2008/06/riajobsorg/&amp;title=riajobs.org" rel="nofollow" title="Add to&nbsp;Google Bookmarks"><img class="social_img" src="http://www.sentientbeings.com/wp-content/plugins/social-bookmarks/images/google.png" title="Add to&nbsp;Google Bookmarks" alt="Add to&nbsp;Google Bookmarks" /></a>
<a onclick="window.open(this.href, '_blank', 'scrollbars=yes,menubar=no,height=600,width=750,resizable=yes,toolbar=no,location=no,status=no'); return false;" href="http://reddit.com/submit?url=http://www.sentientbeings.com/2008/06/riajobsorg/&amp;title=riajobs.org" rel="nofollow" title="Add to&nbsp;reddit"><img class="social_img" src="http://www.sentientbeings.com/wp-content/plugins/social-bookmarks/images/reddit.png" title="Add to&nbsp;reddit" alt="Add to&nbsp;reddit" /></a>
<a onclick="window.open(this.href, '_blank', 'scrollbars=yes,menubar=no,height=600,width=750,resizable=yes,toolbar=no,location=no,status=no'); return false;" href="http://slashdot.org/bookmark.pl?url=http://www.sentientbeings.com/2008/06/riajobsorg/&amp;title=riajobs.org" rel="nofollow" title="Add to&nbsp;Slashdot"><img class="social_img" src="http://www.sentientbeings.com/wp-content/plugins/social-bookmarks/images/slashdot.png" title="Add to&nbsp;Slashdot" alt="Add to&nbsp;Slashdot" /></a>
<a onclick="window.open(this.href, '_blank', 'scrollbars=yes,menubar=no,height=600,width=750,resizable=yes,toolbar=no,location=no,status=no'); return false;" href="http://www.stumbleupon.com/submit.php?url=http://www.sentientbeings.com/2008/06/riajobsorg/&amp;title=riajobs.org" rel="nofollow" title="Add to&nbsp;Stumble Upon"><img class="social_img" src="http://www.sentientbeings.com/wp-content/plugins/social-bookmarks/images/stumbleupon.png" title="Add to&nbsp;Stumble Upon" alt="Add to&nbsp;Stumble Upon" /></a>
<a onclick="window.open(this.href, '_blank', 'scrollbars=yes,menubar=no,height=600,width=750,resizable=yes,toolbar=no,location=no,status=no'); return false;" href="http://www.technorati.com/faves?add=http://www.sentientbeings.com/2008/06/riajobsorg/" rel="nofollow" title="Add to&nbsp;Technorati"><img class="social_img" src="http://www.sentientbeings.com/wp-content/plugins/social-bookmarks/images/technorati.png" title="Add to&nbsp;Technorati" alt="Add to&nbsp;Technorati" /></a>
<a onclick="window.open(this.href, '_blank', 'scrollbars=yes,menubar=no,height=600,width=750,resizable=yes,toolbar=no,location=no,status=no'); return false;" href="http://myweb2.search.yahoo.com/myresults/bookmarklet?u=http://www.sentientbeings.com/2008/06/riajobsorg/&amp;t=riajobs.org" rel="nofollow" title="Add to&nbsp;Yahoo My Web"><img class="social_img" src="http://www.sentientbeings.com/wp-content/plugins/social-bookmarks/images/yahoo.png" title="Add to&nbsp;Yahoo My Web" alt="Add to&nbsp;Yahoo My Web" /></a>
<br />
</div>
</div>
<!-- Social Bookmarks END -->
]]></content:encoded>
			<wfw:commentRss>http://www.sentientbeings.com/2008/06/riajobsorg/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
	</channel>
</rss>
