Is standards compliance so important?

I generally advocate standards compliant code, but sometimes things can go too far. And too far is when it harms the user experience. There’s been a lot of fuss lately over what code to use when embedding flash in a web page and when I read most of it I find myself wondering “what is best for the user”. As a developer, this is sometimes an uncomfortable thought since it usually means more work and like most people I’m inherently lazy. But I try to fight against the laziness and put the user first.

Users just want a web site to work. They don’t care if it validates. Developers want it to validate. Validation is an important tool both for finding errors and future proofing the site and whenever we can make a page that validates we should, but if the only way to do that is to harm the user experience than we shouldn’t. If it’s not possible to produce the ideal user experience and be standards compliant then I’ll always put the user experience first.

So what do I recommend for embedding flash content? Different sites have different needs, but in most cases I would recommend a solution that uses JavaScript for plug-in detection and to embed the flash content or display alternative content as appropriate. UFO or SWFObject should fit the bill, but do create your own if you want. Also, Microsoft’s solution to the Eolas patent problem produces a poor user experience and using JavaScript to embed the flash content circumvents this problem. Until the object tag works properly in all browsers, I think this is probably the best solution there is. If you want instead to try to work around the differences in the various implementations of the object tag, here’s a fairly comprehensive list of resources.

So, to answer the question I started with. Web standards are important for the future of the web. They are important for browser developers, for tools developers, and for site developers. But I’m not going to make a standards compliant site that provides a sub-standard user experience just because I have the mistaken opinion that by doing so I would encourage Microsoft et al to produce browsers that implement the standards or because I hope that future browsers will implement the standards and when they do I won’t have to change the site to work with them. That would be a poor service to provide to my clients and my users.

Leave a Reply

Your email address will not be published. Required fields are marked *