O'Reilly logo

Professional CSS: Cascading Style Sheets for Web Design, Second Edition by Mark Trammell, Dunstan Orchard, Ethan Marcotte, Cindy Li, Todd Dominey, Christopher Schmitt

Stay ahead with the world's most comprehensive technology and business learning platform.

With Safari, you learn the way you learn best. Get unlimited access to videos, live online training, learning paths, books, tutorials, and more.

Start Free Trial

No credit card required

Chapter 1. Best Practices for XHTML and CSS

 

Great works are performed, not by strength, but by perseverance.

 
 --Samuel Johnson

In its early years, the Web wasn't exactly the most attractive thing on the planet. Created by and for nuclear physicists, hypertext was simply a means by which content-heavy documents could be shared over an open, distributed network. Needless to say, high-caliber design wasn't a top priority for the Web's earliest authors. In fact, HTML's much-used (and, as will be discussed, oft-abused) table element was created with one purpose in mind: the display of tabular data.

By the heyday of late-1990s' Web design, the "L" in HTML was often ignored. Many professionals felt that the code used to build Web pages wasn't a language per se and, thus, wasn't subject to the rules and restrictions of a real programming language. Besides, clients weren't paying for "compliant," "accessible," or "future-proof" code. In fact, many sites were produced with the requirement that they be "backward compatible." That was a misnomer if ever there was one because it simply required a consistent display in version 4.0 browsers or higher.

Browsers of that time were temperamental, to say the least. With poor support for the specifications written by the World Wide Web Consortium (W3C) — www.w3.org — you could count on a page rendering differently in Browser A than in Browser B. So, while many programmers were dimly aware of the "standards" the W3C produced, the browsers they had to support ...

With Safari, you learn the way you learn best. Get unlimited access to videos, live online training, learning paths, books, interactive tutorials, and more.

Start Free Trial

No credit card required