I’m trying to fix a website (built by a third party) that loads in a rather strange way. It’s a two column layout (Yes, it uses a table for layout ), and it loads like this:
The first column appears, taking out the whole width of the table
the second column appears, pushing the first column back into place
The effect is most pronounced in Safari, but it also happens (for uncached pages) with IE and Firefox.
The table is width 100%. The second column has a fixed width. The first column doesn’t have a specified width.
It was my understanding that the browsers handled tables in the following order…
work out what’s in the table cells
work our the width required
display the table.
… but that doesn’t seem to be happening for this particular site.
Any thoughts on what’s going on? Possible solutions?
Many thanks in advance… Gary
PS The website is password protected, unfortunately. Otherwise I would have included a link to it.
What’s the HTML construction like? Is it all in a single file, is it pulling fragments from different files or is it writing it on-the-fly? If you could re-write a ‘lorem ipsum’ version that we could see, that might help.
You’re right: when a give the first column a width, the page loads cleanly. So fixing the width of the page is a possible solution. (It’s currently flexible.)
By default the table-layout is set to auto. It usually tends to be slow, since it has to read through the content before determining the final layout.
I prefer a fixed table-layout algorithm. This layout does not depend on the content and lays out faster than the former [auto]. After the first row is received, the browser can begin to display the table.