...

View Full Version : TABLE to DIV



doctrin13th
11-03-2009, 11:43 AM
in my other thread, somebody posted:

Oh.. NO! Don't you know using tables for layout is very bad?

i visit the of why-table-is-bad link in that thread and found out that instead of table, tr,td etc, DIV is the proper(?) way.

i have here a basic and simple example of an html tabled-layout page.


<?xml version="1.0" encoding="iso-8859-1"?>
<!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>
<title>Untitled Document</title>
<meta http-equiv="Content-Type" content="text/html; charset=iso-8859-1" />
</head>

<body>
<table width="600" border="0" align="center" cellpadding="10" cellspacing="0">
<tr>
<td colspan="2" bgcolor="#999999"><h1 align="center">HEADING 1</h1></td>
</tr>
<tr>
<td colspan="2"><table width="519" border="0" align="center" cellpadding="0" cellspacing="0">
<tr>
<td width="177" height="125" bgcolor="#FFFF66"><center>
news</center></td>
<td width="196" bgcolor="#FFFF99"><center>
welcome</center></td>
<td width="96" bgcolor="#FFFFCC"><center>
ads</center></td>
</tr>
</table></td>
</tr>
<tr>
<td width="471" bgcolor="#CCCCFF"><center>
Footer</center></td>
<td width="89" bgcolor="#FFFFCC">Extra Data</td>
</tr>
</table>
</body>
</html>

i don't have any idea on how UN-TABLE layout that page keeping it exactly the way it was(including the way it behaves in the browser)

can somebody help me?

VIPStephan
11-03-2009, 11:47 AM
Looks like a three column layout to me. Have a look at BonRouge.com (http://bonrouge.com/3c-hf-fixed.php), it has everything you need.

effpeetee
11-03-2009, 01:36 PM
You may also find this helpful. (http://www.mardiros.net/liquid-css-layouts.html)

Also much help here. (http://www.exitfegs.co.uk/Sources.html)

Frank

doctrin13th
11-04-2009, 06:52 AM
thanx a lot for the links gentlemen!
but if somebody have time, may i kindly request the conversion of my code to NON-TABLEd one. for in my experiences, i've learned best from examples

but i will consider the links for extra knowledge. thanks again guys

doctrin13th
11-05-2009, 06:51 AM
anybody? please ...



EZ Archive Ads Plugin for vBulletin Copyright 2006 Computer Help Forum