Working together for standards The Web Standards Project

If content is king then valid pages must be the poor suckers down in the dungeon. The Webby winners were announced today, and while certainly some of the most content-rich, culturally valuable, and technically helpful sites are on the roster of winners, there is only one valid home page among ‘em, and that’s the site for the blogging tool, LiveJournal.

Two sites came very close, our friends at Fray just need [make that needed - they fixed it after reading this post!] to add the type attribute to their script element to fix the problem. has two instances of the value "absmiddle" in an HTML 4.01 Transitional document. Get rid of that, and they’re good, too.

Unfortunately, the remaining 50 some-odd sites are suffering from multiple conformance problems, some more serious than others. But instead of downplaying the importance of these great sites, better to see what we can learn from them to improve our markup practices.

The majority of problems found demonstrates common issues developers are either unaware of or struggling with currently. It’s important to point out that often these problems do not originate with the site developers, rather, the content management systems and ad servers they are using.

Whether we’re developing sites or CMS solutions or ad server markup, we all need to get our proverbial acts together. The good news is that most of these things are easy to repair. Common problems found on Webby Award sites include:

  • No document encoding. Ideally, encoding is done on the server. But there are alternatives, and while the lack of encoding isn’t specifically an issue with validation, it should be addressed. This helpful WaSP asks the W3C will explain why.
  • Encoding mismatches. This problem is popping up more and more now that the W3C’s validator has been upgraded. What this means is that the encoding on the server is conflicting with the encoding in the document. If you have the appropriate encoding on the server, please do not add it to your document via the meta element.
  • No DOCTYPE. This may well be the most common error with all non-conforming web sites on the web today. Including a DOCTYPE cannot be seen as frivolity, but as necessity. They are necessary for validation, and in those browsers with DOCTYPE switching, they provide developers with a means to offer those browsers standards-compliant rendering.
  • Use of language attribute in script elements. The language attribute was deprecated in HTML 4.01 and should not be used in HTML 4.01 Strict, XHTML Strict, or XHTML 1.1. The only problems removing the language attribute in script elements could cause involve much older browsers, so in almost every contemporary case, just get out of the habit of using it. Do be sure, however, to include the type attribute and appropriate value: <script type=”text/javascript”> . . . </script>
  • No type attribute in style elements. The type="text/css" value is required in the style element: <style type=”text/css”> . . . </style>
  • No alt attribute. C’mon people now, smile on your sister over here. Just how long are we going to have to fight this battle? Make it easy on yourselves, if you’ve got an image, include the alt attribute.
  • Mixed HTML and XHTML syntax. This one is an interesting issue I’m seeing pop up a lot. It’s likely that many sites are in the process of conversion and simply haven’t updated their syntax in certain documents. But I have a nagging doubt in my mind that part of the problem might be arising from documents that are being worked on by numerous people, and there’s no style guide for the site to help guide their practices.
  • Proprietary attributes for presentation such as leftmargin in the body element. Only in very few cases should we fall back on proprietary attributes. CSS is a far smarter, better means of managing presentation. Even if you have to support older browsers, clever use of very streamlined tables for layout along with CSS can reduce or eliminate the need for these types of attributes.
  • No escaping entities. Also an extremely common problem, if you’re using XHTML, you’ll want to escape any ampersand in URLs or embedded scripts: becomes;story.html. This will not affect the link or script performance, but not escaping the ampersand in XHTML documents will definitely cause your documents to be invalid.

Congratulations to all the Webby winners. The content and design of many of the winning sites is worthy of royal acknowledgement. Correction of these common errors is a prize worth fighting for despite those royal honors, resulting in more accessible, usable, fast-loading and compliant sites.

Return to top

Post a Reply

Comments are closed.

All of the entries posted in WaSP Buzz express the opinions of their individual authors. They do not necessarily reflect the plans or positions of the Web Standards Project as a group.

This site is valid XHTML 1.0 Strict, CSS | Get Buzz via RSS or Atom | Colophon | Legal