![]() |
|
| View Poll Results: What is more portable? | |||
| Tables |
|
2 | 20.00% |
| Divs |
|
8 | 80.00% |
| Voters: 10. You may not vote on this poll | |||
![]() |
|
|
Thread Tools | Display Modes |
|
|
#1 |
|
Hobbyist Programmer
Join Date: Jun 2007
Posts: 133
Rep Power: 2
![]() |
Div vs Table Layouts - Your opinion
When it comes down to positioning, I believe tables are more portable across browsers. Using tables to layout your site (not that i do) generates a lot of extra code but now with faster connections does more code really mean much less performance? taking into consideration how the layout will require minimal browser compatibility patches and most screen readers will still read the content.
My question is why, when you realistically look at tables vs divs, is it more sensible to use tables to layout your site? After all google still uses tables to layout their site. |
|
|
|
|
|
#2 |
|
King of Portal
|
Re: Div vs Table Layouts - Your opinion
I've read it elsewhere in the past and all the css gurus seem to agree that divs are what should be used for layouts. Tables should only EVER be used for tabular data. That's what they're for. I used to use tables for everything because they were easy to position without knowledge of css. However, I do realize the benefits of using divs in terms of different style sheets. Just take a look at css Zen Garden. I believe everything is with divs, and therefore, the different styles isn't something you could achieve with tables.
__________________
Lo, there do I see my father. 'Lo, there do I see My mother, and my sisters, and my brothers. 'Lo, there do I see The line of my people... Back to the beginning. 'Lo, they do call to me. They bid me take my place among them. In the halls of Valhalla... Where the brave... May live... ...forever.. GrimBB | Mimesis |
|
|
|
|
|
#3 |
|
Battle Programmer
Join Date: Feb 2006
Location: Bellevue, WA, USA
Posts: 763
Rep Power: 3
![]() |
Re: Div vs Table Layouts - Your opinion
AFAIK, tables are easier for code generators (i.e. WYSIWYG editors) to get the layout "correct." I use quotes because it may look one way in the editor and possibly another in the browser.
__________________
<insert disclaimer here> <insert shameless plug for Visual Studio here> |
|
|
|
|
|
#4 |
|
Newbie
Join Date: Dec 2007
Posts: 3
Rep Power: 0
![]() |
Re: Div vs Table Layouts - Your opinion
in my Blog , I use Div
most of users advised me to use div it became faster but as you say it's suitable for Iexplorer and few - to some extent- browsers |
|
|
|
|
|
#5 | |
|
Expert Programmer
|
Re: Div vs Table Layouts - Your opinion
Quote:
What the hell does that mean? It is complete nonsense. Last edited by titaniumdecoy; Dec 26th, 2007 at 11:29 AM. |
|
|
|
|
|
|
#6 |
|
Hobbyist Programmer
![]() Join Date: Oct 2007
Location: New York
Posts: 163
Rep Power: 10
![]() |
Re: Div vs Table Layouts - Your opinion
Most web browsers, most notably Internet Explorer, render div tags MUCH faster than tables. The reason for this is because tables don't render themselves until everything contained within them is loaded, while div tags load their elements subsequently. Therefore, if you have a two column layout set up through a table, when a user loads a page, they're going to see a blank page for a second or two before, suddenly, everything pops into place all at once. If you use div tags to create a layout, each element will pop into place as soon as its loaded, right from the start.
__________________
DaniWeb IT Discussion Community Everything Information Technology related all in one convenient interactive online publication and community |
|
|
|
|
|
#7 | |
|
Professional Programmer
Join Date: May 2005
Location: Woo - Boot Sector!
Posts: 294
Rep Power: 4
![]() |
Re: Div vs Table Layouts - Your opinion
Quote:
But one better than using divs for layouts is to use proper tags, e.g. paragraphs and stuff. A div is to divide up a page into different segments, not to use as basically a table cell; that defeats the purpose of css, and is just as bad as table layout.
__________________
www.heldtogether.co.uk |
|
|
|
|
|
|
#8 |
|
Newbie
Join Date: Dec 2007
Posts: 5
Rep Power: 0
![]() |
Re: Div vs Table Layouts - Your opinion
I like Divs because you can do so much more with them and you can put them really anywhere you want.
__________________
ME Cave Community Profile||Myspace Profile Cool Websites Cave Community||Will Host For Food |
|
|
|
|
|
#9 |
|
Hobbyist Programmer
Join Date: Jun 2007
Posts: 133
Rep Power: 2
![]() |
Re: Div vs Table Layouts - Your opinion
The only reason i use divs is to keep my code tidy, using tables gets confusing once you get past 2-3 levels of nesting..
hopefully soon all browsers can pass the acid 2 test and we can stop discussing how to create cross browser layouts easily. |
|
|
|
|
|
#10 |
|
Newbie
Join Date: Dec 2007
Posts: 14
Rep Power: 0
![]() |
Re: Div vs Table Layouts - Your opinion
div's are used for layouts, tables are used for data.
|
|
|
|
![]() |
| Bookmarks |
| Currently Active Users Viewing This Thread: 1 (0 members and 1 guests) | |
| Thread Tools | |
| Display Modes | |
|
|
Similar Threads
|
||||
| Thread | Thread Starter | Forum | Replies | Last Post |
| 100% Table Height using Firefox | hoffmandirt | ASP.NET | 2 | Jun 23rd, 2006 9:34 AM |
| mysql table view require()or suggestions. | piercy | PHP | 15 | Apr 28th, 2006 6:29 AM |
| word wrap in a table cell? | kerriganm | HTML / XHTML / CSS | 4 | May 6th, 2005 5:38 PM |
| Table in C language??? | Planet_EN | C++ | 5 | Mar 31st, 2005 10:09 AM |
| Calling a function in a table | Navid | JavaScript and Client-Side Browser Scripting | 2 | Mar 11th, 2005 11:09 AM |