Table’s vs Floating Div’s, a commonly mis-understood argument.

A while back, the introduction to strict HTML, or XHTML, came about. Before CSS, developers were organizing and styling content using Tables. It’s still done today. CSS revolutionized websites and the need for tables looked like a thing of the past. The use of Floating Div took off. If you understood it and could implement everything cleanly, it made you special in the world of Front-end GUI developers.

I jumped on the train too. But the truth of the matter is that tables are here to stay. Floating Div’s serve a purpose of styling content and organization, while tables are to structure data content. So the use of both have to be carefully thought out.

If you are organizing your website and styling data, you want to try and stick with Floating Div’s. But if you are laying out a structure for a specific set of data, use a Table.

Another way to stay in check is if you notice yourself using rowspan and colspan too much in a table and there is too much content within your TD tags, it’s probably because you’ve escaped specific sets of data and have moved to styling and organizing, therefore Floating Div’s should be used. Forms commonly use tables for organization of labels and input boxes. You would then be structuring data input. But you can use CSS to accomplish the same goal.

That said, CSS supports tables, [display: table] [display:table-cell]. In-fact, if you want any sort of vertical alignment, you have to be within a table-cell before its possible. Floating Div’s and Tables are tools in your toolbox. If you are spending too much time trying to solve a problem, remember to revisit your toolbox.

About Phillihp Harmon

I'm Phillihp. My name can be spelled the same way forwards and backwards, so can my posts... if you wish. I'm out here exploring, learning, and sharing what I find. This is more for fun and personal growth, I aim to be as consistent as possible, so check back daily!
This entry was posted in Browsers, Design, HTML5/CSS3, Internet, Mobility. Bookmark the permalink.

One Response to Table’s vs Floating Div’s, a commonly mis-understood argument.

Leave a Reply

Your email address will not be published. Required fields are marked *