Why do Google and Twitter use table layout? [dupli

2019-01-21 16:30发布

Possible Duplicate:
Does it make sense to use the <table> tag on a “modern” website?

Everywhere I go I see don't use table layout, it's evil, even Google says that, so why one of the most visited websites, Google and Twitter, use it for their homepage?

I don't think it is any kind of mistake, or any other stupid problem.

The only reason I can think of is, that they want the page to look similar even if client doesn't support CSS, like with Lynx.

So why everyone say it is so bad, if the biggest websites on the internet use it.

In my opinion, there are some cases, like those mentioned above, where it is vitaly important to have the same look everywhere, than it is OK to use tables.

edit: The same question goes about html elements like <center>, or formatting text with attribute align and other "html attributes and elements used to substitute CSS functionality"

9条回答
疯言疯语
2楼-- · 2019-01-21 16:39

Table layout gets more grief than it deserves. It's easy for developers to use, it's consistent across nearly every web browser, and it allows you to easily add rows/columns with little to no effort.

The only downside is that it goes against the mantra that your document should only contain content, and your design should be contained separately (in a CSS file).

查看更多
贪生不怕死
3楼-- · 2019-01-21 16:41

Page load time is king for these guys, and bandwidth usage is extreme.

I'd have to say they use tables for raw data speed, since they are serving up so much bandwidth every day.

Also, notice that they use inline styles in the page header to reduce the number of HTTP requests to help speed up page load time.

查看更多
孤傲高冷的网名
4楼-- · 2019-01-21 16:45

Twitter works pretty well from phones in web mode. Some web browsers are truly gruesome, so I assume Twitter does what it has to.

Given how poorly so many web sites work on phones, I'm more concerned about mobile compatibility than with the concerns of CSS evangelicals.

查看更多
Ridiculous、
5楼-- · 2019-01-21 16:53

Google doesn't have to care about ranking high in search engines... ;)

查看更多
家丑人穷心不美
6楼-- · 2019-01-21 16:54

Table layout is working on most browsers. Google and others want to reach all user, not some or only modern users. Having different layouts or layout technologies is hard to maintain and costly in delivering content. Table layout is not tricky. Its straight forward. You dont have to look for css hacks, browser incompatibilities or others.

Table layouts are bad. Because thy mix layout and content.

查看更多
Animai°情兽
7楼-- · 2019-01-21 16:55

It's evil, it's a pain, but rendering is pretty much guaranteed to be consistent across different browsers.

查看更多
登录 后发表回答