Web Design Nirvana Without the Web Standards


podcast_icon

The Web standards zealots have been running rampant on the Web, spewing their tripe of how you must follow the Web standards no matter what is happening in the real world.

… Why pay attention how (the most popular) web browsers read and understand code? To hell with them, so says the Web standards zealots.

No, instead of pulling our heads out of the sand, we should follow the W3C wish list of how code should be rendered, and use a bunch of fragile hacks to make our pie-in-the-sky code work.

DON’T BE FOOLED

As you read this, you may be asking yourself why would anyone ignore reality? If it’s raining, it makes sense to use an umbrella - even if the weather man says it ain’t raining!

Well, I would have to agree with you. After I read the weather reports, I look outside…

Unfortunately, many in the web design community haven’t. They blindly follow the teachings of the web standard zealots, despite the facts their websites are hacked up, require more work than necessary, and add no real value or advantage to the web site.

WEB STANDARDS MYTH DEBUNKED

I will not go into the details here, I’ve covered that elsewhere. But consider these myths:

  1. By following the Web standards you will save money on bandwidth: yes, bandwidth is expensive (sarcasm) and saving a few kilobytes is going to make a difference … ya right!
  2. By following the Web standards your code will be forward compatible: except for your hacks where many have broke in IE 7 - I hate to say it, but I told you so!

Clean code (regardless if it is Web standards compliant or not) makes for easier to maintain pages. Most (99.999%) of us are building average websites where bandwidth limitations are not even being approached - hosting is dirt cheap and getting cheaper all the time!

In the days of high-speed Internet, video (Youtube) and mp3, to quibble about 5k savings on a web page is a classic example of the old expression ‘penny wise and pound foolish’.

XHTML FOOLISHNESS

Along with Web standards foolishness comes XHTML foolishness. First a little background:

Nerds, being what they are, love to get the ‘latest and the greatest’ - makes them feel special. So it is only natural that they gravitate to XHTML - the new and better HTML. Yes nerds, I know XHTML is XML.

The point is that XHTML is not ready for prime-time … if you know what I mean. It has two major flaws today:

  1. IE6 and IE7 will not render XHTML properly, so all the supposed advantages are totally lost!
  2. XHTML makes working with the DOM (and thus AJAX) a real pain. Since AJAX is the future of web application development it would seem silly to me to hinder DOM scripting in any way.

I mention XHTML because many Web standards zealots are enamored with XHTML, and so the pattern of continued denial of reality goes on. Tisk, tisk tisk.

WEB DESIGN NIRVANA

I hate it when people bellyache but don’t offer a solution, so here it is:

  • Use the latest HTML and just be sure to close your tags and that the code is properly formed. This makes the pages easier to maintain and makes DOM scripting work easier.
  • Don’t use hacks! Use IE conditional comments to deal with browser issues like IE6’s problems with CSS positioning etc.

The real world Web standards are found in the browsers being used, not what the W3C would like them to be.

Best,

Stefan Mischook

www.killersites.com
www.killerphp.com

4 Responses to “Web Design Nirvana Without the Web Standards”


  1. 1 Jonathan Nicol

    You suggest writing cleanly formed HTML, and using conditional comments to feed alternative CSS styles to IE6 to work around its poor implementation of CSS. In what way exactly is the approach you suggest different from adhering to web standards? Isn’t writing clean markup at the heart of standards compliance? Unless you have some other definition of ‘clean HTML’?

    You say that the ‘real-world standards’ are to be found in the browsers. To my knowledge all of the browser manufacturers take web standards very seriously, and developing standards compliant sites for the current generation of browsers (Safari 2, Firefox 2, Opera 9, Netscape 8, Internet Explorer 7) is a relatively straightforward business. Admittedly Microsoft are still playing catch up with IE7, but the direction they are headed in seems fairly clear.

    The only widely used browser that has truly cruddy standards support today is IE6. You yourself advocate the use of conditional comments to feed different stylesheets to IE6, to work around its poor CSS implementation. To me, this indicates that you are writing for modern standards compliant browsers first, and then tweaking your CSS to make sure the layout doesn’t break in IE6. This is exactly the approach that almost every real-world standards advocate I know endorses: I can’t think of *anyone* who says “to hell” with the popular web browsers. To ignore IE6 would be commercial suicide for a web designer.

  2. 2 Stefan Mischook

    “In what way exactly is the approach you suggest different from adhering to web standards?”

    Conditional comments are not part of the web standards.

    “Isn’t writing clean markup at the heart of standards compliance? ”

    It could be interpreted that way, but you can write clean code that doesn’t follow the web standards one bit … so to answer your question: no.

    .. Writing clean code is writing clean code, regardless of the language.

    Standards compliance (on the other hand,) is all about using code that the W3C certifies as being correct.

    “To me, this indicates that you are writing for modern standards compliant browsers first, and then tweaking your CSS to make sure the layout doesn’t break in IE6.”

    This is my approach because technically it makes sense. But my major concern is IE6 since today, it still represents the vast majority of web surfers.

    “I can’t think of *anyone* who says “to hell” with the popular web browsers.”

    Several authors have advocated the use of hacks, several have suggested that IE6 is ‘just one of the browsers’ - the implication that it is somehow just one of many … it is the ‘many’.

    - Safari 2, Firefox 2, Opera 9, Netscape 8, Internet Explorer 7 = (maybe 30% of the audience.)

    “To ignore IE6 would be commercial suicide for a web designer.”

    I agree. And yet, I have found myself on many a Web standards compliant website where the code breaks in IE6.

    An example of this is found in this very Wordpress theme .. the default theme no less that screws up in IE6. I had to rewrite some of the code to make it work in IE as it did in FF.

    Thanks for the comments.

    Stefan

  3. 3 Jonathan Nicol

    Hey Stefan, thanks for your reply to my comment.

    “Conditional comments are not part of the web standards.”

    True - I guess what I meant was that conditional comments are used as a means of feeding alternate stylesheets to IE6, allowing the designer to code in a forward looking manner, without hanging an old buggy browser out to dry. In this sense I think of conditional comments as a powerful weapon in the standards conscious web designers arsenal, a method to keep a site hack free without ignoring a browser that still commands an 80% market share.

    I don’t see standards as a hinderance to my design process. Writing standards compliant (X)HTML markup isn’t difficult, and to my mind really just formalizes many conventions that were previously considered to be ‘best practice’: surrounding attributes in quotes, writing tags in lowercase, closing tags, etc. I find the process of validating my markup useful for spotting errors and shortfallings in my code, and oftentimes validation will draw my attention to the root cause of a layout ‘bug’.

    The trickier bit is separating markup from presentation (ie: dropping tables for layout and using CSS instead). In this respect, supporting IE6 does add slightly to development time. But personally I would rather be writing sites for the minority (the standards compliant browsers) first, and retrospectively adding workarounds to keep things looking good in IE6. It may be a wee way off, but now that IE7 is released IE6 usage will begin to dwindle, and I do not want to be tethered to bad coding practices necessitated by this dying browser.

  4. 4 Stefan Mischook

    “… separating markup from presentation”

    This to me, is the one of the two huge advantages of CSS based design. (I never liked locking page structure to layout, as you have with tables.)

    In fact, this disassociation of page-layout from structure is the main reason I put up with CSS’ shortcomings:

    The CSS page-level layout paradigm sucks.

    The other advantage of CSS, is of course the centralization of presentation code in a style sheet - the ‘cascade’ in CSS.

    I appreciate your comments.

    Stefan

Leave a Reply