Martin Heller
Contributing Writer

Review: “Everything You Know About CSS Is Wrong!”

analysis
Dec 29, 20083 mins

The big issue here is that the most prevalent browser is Internet Explorer (IE), and that prior to version 8 IE did not support CSS tables. The authors show you a way to deal with this problem and use CSS tables, although their position is controversial.

Everything You Know About CSS Is Wrong!, By Rachel Andrew & Kevin Yank

Edition: 1st

Price: $29.95

Pages: 130

ISBN: 978-0-9804552-2-9

Published: October 2008

This aggressively titled, well-written book is about CSS tables. As you may know, most browsers already support CSS tables, meaning the CSS properties “display: table,” “display: table-row,” “display: table-cell,” and so on.

“Most browsers” does not, unfortunately, equate to “most people using browsers.” The big issue here is that the most prevalent browser at most sites is Microsoft Internet Explorer (IE), and that prior to version 8 IE did not support CSS tables. Sure, let’s tell 80 percent of our visitors that they can’t view our content correctly. Gulp. NOT!

Now that IE 8 is about to ship, it might start to make sense to use CSS tables instead of CSS floats, which are hard to do well on multiple browsers, or HTML tables, which are easy to use but often don’t look that great. But what can we do about people with IE 7 and IE 6? This is 2001 all over again, with IE 7 taking the place of Netscape 4, and the one big thing we learned back then is that people don’t take kindly to being told what browser to use: they want the site to accommodate to the browser currently in use.

Andrew and Yank make a compelling case for the position that it is time to adopt CSS tables, while handling older versions of IE with conditionally included CSS. They provide short, clear examples of how to do this, at least for some relatively simple common cases. The basic argument here is that adopting CSS tables is the way to move forward; the secondary argument is that using standard CSS tables and adding the conditionally included CSS for IE 6 and IE 7 is less of a development and testing burden than using CSS floats and tuning them to work on seven different browsers.

That’s right, seven browsers — in my experience, if you want to cover the gamut, you need to test on IE 8, IE 7, IE 6, Firefox, Safari, Opera, and Chrome. Most other browsers are variations on the above seven that don’t introduce additional rendering engines or extensions, although that could change at any time; it was only a few months ago that I had to add Chrome to my testing list, and Google didn’t exactly give us a lot of warning about it.

Not everyone will agree with Andrew and Yank’s position, least of all people with thousands of existing pages already designed, tested, debugged, and serving multiple browsers. But it’s certainly an argument worth examining, especially when your next site redesign comes around.

By the way, the first printing of Everything You Know About CSS Is Wrong! has sold out. It’s available as a PDF now and will be in print again in mid-January.

Martin Heller

Martin Heller is a contributing writer at InfoWorld. Formerly a web and Windows programming consultant, he developed databases, software, and websites from his office in Andover, Massachusetts, from 1986 to 2010. From 2010 to August of 2012, Martin was vice president of technology and education at Alpha Software. From March 2013 to January 2014, he was chairman of Tubifi, maker of a cloud-based video editor, having previously served as CEO.

Martin is the author or co-author of nearly a dozen PC software packages and half a dozen Web applications. He is also the author of several books on Windows programming. As a consultant, Martin has worked with companies of all sizes to design, develop, improve, and/or debug Windows, web, and database applications, and has performed strategic business consulting for high-tech corporations ranging from tiny to Fortune 100 and from local to multinational.

Martin’s specialties include programming languages C++, Python, C#, JavaScript, and SQL, and databases PostgreSQL, MySQL, Microsoft SQL Server, Oracle Database, Google Cloud Spanner, CockroachDB, MongoDB, Cassandra, and Couchbase. He writes about software development, data management, analytics, AI, and machine learning, contributing technology analyses, explainers, how-to articles, and hands-on reviews of software development tools, data platforms, AI models, machine learning libraries, and much more.

More from this author