Quote:
Originally Posted by cambaby
CSS example 548 characters
Table example 470 characters
Now duplicate that across an entire website
Plus you forgot to add formatting for the various IE bugs in your CSS example
Also keep in mind if if you used a seperate .css thats loading 2 files instead of 1
These are all penalties for search engines but using a table is never a penalty
|
Wrong. Because as soon as you add in any other elements or styling to this layout. The table one exponentially gets more and more bloated.
Also, there is no various IE bugs in my CSS example. That code would work all the way back to IE4 and probably further. You obviously don't know what you're talking about.
Anyway, here is my point as to once you start adding more to the layout, tables become more bloated. In the example, I will add just one single block to each column.
Code:
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<html xmlns="http://www.w3.org/1999/xhtml">
<head>
<meta http-equiv="Content-Type" content="text/html; charset=UTF-8" />
<title>Untitled Document</title>
<style type="text/css">
.wrap{width:600px;clear:both;}
.column{width:200px;float:left;}
.block{width:200px;}
</style>
</head>
<body>
<div class="wrap">
<div class="column">
<div class="block">stuff in the left column</div>
</div>
<div class="column">
<div class="block">stuff in the center column</div>
</div>
<div class="column">
<div class="block">stuff in the right column</div>
</div>
<div class="wrap"></div>
</div>
</body>
</html>
Code:
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<html xmlns="http://www.w3.org/1999/xhtml">
<head>
<meta http-equiv="Content-Type" content="text/html; charset=UTF-8" />
<title>Untitled Document</title>
</head>
<body>
<table width="600" cellpadding="0" cellspacing="0">
<tr>
<td width="200">
<table width="200" cellpadding="0" cellspacing="0">
<tr>
<td>stuff in left column</td>
</tr>
</table>
</td>
<td width="200">
<table width="200" cellpadding="0" cellspacing="0">
<tr>
<td>stuff in center column</td>
</tr>
</table>
</td>
<td width="200">
<table width="200" cellpadding="0" cellspacing="0">
<tr>
<td>stuff in right column</td>
</tr>
</table>
</td>
</tr>
</table>
</body>
</html>
The more complex the layout gets, the worse and worse the code gets. I actually think you're fucking with me and everyone here for shits and giggles. I couldn't imagine anyone in this day n age not understanding the basic principles of html.