Welcome, Guest: Register On Nairaland / LOGIN! / Trending / Recent / New
Stats: 3,153,245 members, 7,818,839 topics. Date: Monday, 06 May 2024 at 06:19 AM

What Are The Advantages And Disadvantages Of Using Table For Layout - Webmasters - Nairaland

Nairaland Forum / Science/Technology / Webmasters / What Are The Advantages And Disadvantages Of Using Table For Layout (19077 Views)

Disadvantages Of Dating A Blogger (website Owner). / The New Layout Of GtBank's Internet Banking Portal / Nairaland's New Background And Layout Style (2) (3) (4)

(1) (Reply) (Go Down)

What Are The Advantages And Disadvantages Of Using Table For Layout by deco2come: 12:44pm On Apr 28, 2011
I find using table so easy for layouts. Though I know how to use Div as well but using table makes my work faster. Is there disadvantages of using tables. What are the advantages and disadvantages of using both?
Re: What Are The Advantages And Disadvantages Of Using Table For Layout by yawatide(f): 3:33pm On Apr 28, 2011
Though I know how to use Div as well but using table makes my work faster.

Do you read the Bible? If you do, are you familiar with the portion that says (in part), "straight is the road that leads hell"? My point: Making work faster isn't always equated with making work efficient.

Here is the answer to your question, in a nutshell:

Use tables only when you are presenting tabular data on your page(s). Don't use it for layout because:
1) Tables weren't originally meant for layout
2) Tables add unnecessary weight to your pages which means those will low bandwidth will take forever to download such pages
3) Using tables for layout makes the code harder to read and maintain, especially if you don't indent

Good luck!
Re: What Are The Advantages And Disadvantages Of Using Table For Layout by Nobody: 4:28pm On Apr 28, 2011
Somehow, i dont believe table is faster at all.

Imagine doing a sidebar like this

[sidebar style='width:cvcvc;float:left']
html markups including table and td. . .up to 1000 lines
[/sidebar]

If you do the same with tables, you will start looking for where
one TD ends and another starts. But if you are using dreamweaver sha, you can always use the expanded tables layout.
But if you work in various environments like me, you will find out that you cannot do that all the time.

Then, for compatibility with lots of downloaded scripts, mobile phone compatibilities and several other things, i find DIV
layouts very very good.

And like yawatide said, tables were not originally meant for layouts, it just looks like the easiest way out kind of.
Re: What Are The Advantages And Disadvantages Of Using Table For Layout by deco2come: 11:15pm On Apr 28, 2011
Thanks for all the answers. I checked nairaland source, and other forums; they are 80% tables and despite that, their speed to load is still faster compare to www.yahoo.com.

Regarding to being hard to read, you guys are absolutely correct.
Re: What Are The Advantages And Disadvantages Of Using Table For Layout by yawatide(f): 8:55am On Apr 29, 2011
1) Have you compared the SMF version of this NL versus the current SMF version?
2) Bandwidth isn't just about tables. Do you know if other optimizations have been carried out, behind the scenes?
3) I assume you are aware that yahoo.com does a lot more "work" than NL does.
Re: What Are The Advantages And Disadvantages Of Using Table For Layout by Nobody: 12:21pm On Apr 29, 2011
Site 1
[html]
[head]
[title]Template 1[/title]
[/head]
[body]

[table width="1000" align="center"]
[tr]
[td bgcolor="red"] [/td]
[td height="100" bgcolor="red"]
Logo Area
[/td]
[td bgcolor="red"] [/td]
[/tr]

[tr valign="top"]
[td width="100" height="500" bgcolor="red"]
Left Sidebar
[/td]

[td bgcolor="blue"]
Content of website.Content of website.Content of website.Content of website.Content of website.
Content of website.Content of website.Content of website.Content of website.Content of website.
Content of website.Content of website.Content of website.Content of website.Content of website.
[/td]


[td width="100" height="500" bgcolor="red"]
Right Sidebar
[/td]
[/tr]

[tr]
[td bgcolor="red"] [/td]
[td height="50" bgcolor="red" align="center"]
Copyright hotels Nigeria, All rights reserved.
[/td]
[td bgcolor="red"] [/td]
[/tr]

[/body]
[/html]
Re: What Are The Advantages And Disadvantages Of Using Table For Layout by Nobody: 12:22pm On Apr 29, 2011
Site 2:

[html]
[head]
[title]Template 2[/title]
[/head]
[body bgcolor="black" style="margin:0px"]

[div style="width:800px;background:#ffffff;min-height:750px;margin-left:auto;margin-right:auto"]

[div style="background:red;height:100px;font:30px tahoma;padding-top:20px;padding-left:100px;"]
Logo Area
[/div]


[div style="width:100px;height:700px;background:blue;float:left"]
Left Sidebar

Left Sidebar

Left Sidebar

Left Sidebar

[/div]


[div style="width:100px;height:700px;background:blue;float:right"]
Right Sidebar

Right Sidebar

Right Sidebar

Right Sidebar

[/div]


[div style="background:silver;width:600px;height:700px;margin-left:auto;margin-right:auto"]
Content of website.Content of website.Content of website.Content of website.Content of website.
Content of website.Content of website.Content of website.Content of website.Content of website.
Content of website.Content of website.Content of website.Content of website.Content of website.
[/div]


[div style="height:50px;background:red;clear:both"]
Copyright hotels Nigeria, All rights reserved.
[/div]



[/div]

[/body]
[/html]
Re: What Are The Advantages And Disadvantages Of Using Table For Layout by bouzymill2: 7:53pm On Apr 29, 2011
*dhtml:

Site 2:

[div style="width:800px;background:#ffffff;min-height:750px;margin-left:auto;margin-right:auto"]

[div style="background:red;height:100px;font:30px tahoma;padding-top:20px;padding-left:100px;"]


Why do you always write your style Inline? #Justasking
Re: What Are The Advantages And Disadvantages Of Using Table For Layout by SpikesC1: 10:51pm On Apr 29, 2011
Why did you guys answer to this thread, *dhtml,you dey fall my hand o. At OP,don't you surf the net,the war between table layout and css has been fought since 10000 BC and you still get mouth bring up the topic here. Abeg,go to the nearest computer center and register for a full program in web designing,that will help you a lot *no offense*

(1) (Reply)

Yahoo! Nigeria / INTERSWITCH/QUICKTELLER Won't Return My Funds After A Failed Transaction! / The New Layout Of GtBank's Internet Banking Portal

(Go Up)

Sections: politics (1) business autos (1) jobs (1) career education (1) romance computers phones travel sports fashion health
religion celebs tv-movies music-radio literature webmasters programming techmarket

Links: (1) (2) (3) (4) (5) (6) (7) (8) (9) (10)

Nairaland - Copyright © 2005 - 2024 Oluwaseun Osewa. All rights reserved. See How To Advertise. 21
Disclaimer: Every Nairaland member is solely responsible for anything that he/she posts or uploads on Nairaland.