Hello, I find some times using table is pretty much easy as compared to div. Which one is best technique to use div or tables in your html designing. Danny
<div> is a html element just like <table>, <p> and everything else. Each has a job they do well. Tables are never to be used for layout. That is not their purpose. A div is a general purpose container of other elements. Tables are used to line up tabular data. Choose the one appropriate for the task at hand. If you are having problems lining up div elements how you want, it's because you don't understand how to use CSS to do so. The problem is not the div element itself.
My opinion is its better to use div as we can get better positioning and placing. In particular places like retrieving DB data and other such we such choose for table inside div. With the div browsers issues can be solved easily.
i used to use tables earlier when i wasnt good at css. if you know some css, then divs are the way to go...
DIV is better for SEO for the less html code.Table is better for desgin speed and cross browser.I prefer to combine them, need traffic and seo, use DIV, the others are in table.
Sure it makes sense. All drhowarddrfine was doing was RESTATING the following quote to clarify it for other clueless people. Not drhowarddrfine's fault that clueless people are really that clueless and not likely to have a clue that he is being sarcastic because of such a clueless nonsensical statement by one of the clueless on this board.
I just quoted the wrong post, lol.... Anyways why to compare tables and divs to begin with?? They have both some different functions... And just to respond to the question of our fellow OP : Tables are not to be used AT ALL, they are obsolete in HTML5, use divs even for tabs This is another nonsense, and how the heck can tables be faster more compatible?? Yet the first part is even more hilarious!
Please, stop playing a smartass... You know what I meant, the OP wants to use tables for element positioning, which is wrong.... And what I stated is also true, you have shown me some outdated document, but the tables ARE obsolete in HTML5. I really dunno why, I think they are just supporting the CSS more...
I know what you meant. The problem is, YOU don't know what you meant. Hm. The current W3C HTML5 working document is outdated? It's date-stamped Dec 16, 2011. Hm. Please point me to another which is more up to date. I may be a smartass but at least I'm not a dumbass like you. WHATWG HTML5 Living Standard December 16, 2011