Hi all. Just wondering what you consider to be too deep for nesting tables and putting content in them? Where do you personally draw the line? Obviously tables give you some nice visual options. Thanks! Brian
It all depends on the content you put in them. If I remember correctly, browsers like IE only display the content once the appropriate </table> is found. So imagine you have 3 levels of nested tables, each containing cells with tables in them with pictures and lots of text and the such. The poor user will have to wait for all the content to be downloaded and the table to be closed before anything will show... Luckily Firefox can show tables on the fly, but the majority of people still use IE You you plan on using a design that requires a bit of nesting I'd say go for divs. It can be more complex to have cross-browser compatibility but the code will be much less.
I'm not going beyond 3 (at least any more), but I find I have the most layout flexibility with 3. I'll try and aim for 2, but that gets kinds hard the way my layout is. Brian
Personally I like tables over divs, but you could make a compromise and use both. I've recently designed a site for a friend who was hosting on a cheap, rubbish ISP. Because of this, I was forced to use nested divs to achieve the nice border we came up with (with would have taken 4 nested tables to achieve ), then used a table with a nested one for the actual content. It turned out quite nicely
You should also make sure to remember that whatever comes first in the HTML will be considered by search engine spiders to be the main focus of the webpage. This is regardless of how the tables eventually get laid out on the screen.
2 is the limit I set, and even then no dynamic content in there. 3 is pushing it as the spider might choke and not spider the site well, I have seen this happen so many times you would not believe.
I limit myself at 2. The range of flexiblity you have at 2 is more than enough for 99% of situations.
I actually like to use a mixture.. for the overall table layout, I never go over 2, everything inside those few layout cells can be easily handled and well-formed in all browsers by using div tags inside each of the cells (with the corresponding layout properties of course).
I usually only have two at the most. And the first one is invisible and only there to position the second ones.
Thanks everyone. Did you know a while back I got lazy and went as deep as 4 or 5? This was before I even thought of SEO, and was doing the whole Dreamweaver thing without looking at code. Brian
Even if you were to go beyond 2... it makes future updates and maintenance more difficult as the deeper you go, the easier it is to whack out the entire table set with one mis-sized (or tagged) graphic. There is elegance in simplicity.
Yup. And the more you actually think about layout using tables, the more you can squeeze out of them using less. Brian
Avoid tables! While using pure CSS design will cost you some time in the short term, it will help you massively in the long term. You will see your bandwidth use decrease, and your time spent on maintenance will drop dramatically. Using CSS means that you will have a SINGLE FILE for all your site's layout / display detail - leaving the content up to your HTML. It goes without saying that CSS design is fantastic for SEO, since the crawler will see only the content, unencumbered by additional, unnecessary markup. Just my 2p