Creating Valid HTML Is a Waste of Time, But it Shouldn't Be
Monday, October 20, 2014
Creating Valid HTML Is a Waste of Time, But It Shouldn't Be
HTML is a relatively straightforward markup language. As the primary language of the world wide web, its use is everywhere and its rules are known to the masses.
That being said, the masses aren't particularly careful coders. In fact, at the time of this post, even tech giants such as Microsoft, Google and MIT have errors on their front pages.
Ensuring validity of one's HTML can be both tedious and annoying - especially when dealing with auto-generated HTML, such as the markup that forms the majority of this very site. Yet, I have taken care to ensure that I'm following all the rules while others are throwing sloppy code together and hoping that perople's browsers will somehow be able to figure out what the code is supposed to do and act accordingly.
So why does this corporate website act differently than such highly asteemed technical titans?
There are two simple reasons:
- We have to maintain it. We have to make sure that it works in every browser. Every second we spend tracking down a quirk or answering a question is a second that can't be dedicated to more profitable endeavors. By taking the longview, we spend a bit of time upfront and save substantial time down the road.
- Pride in craftsmanship. Would you trust a mechanic who drives a car rife with dents, scratches and leaky parts? Of course not.
I worked with a Fortune 100 company that used a team that didn't build to standards, despite my strong protests. The managers argued that what was being generated worked, so there was no point building the web application properly. Less than a year later, their clients could no longer use the system. They had updated their web browsers and the broken HTML they were being fed no longer produced readable pages.
The company learned that saving money in the short run isn't always a good idea, and I learn how very difficult it can be to bite one's own tongue.
If you want to check the validity of this page or any other, don't hesitate to do so with W3C Validator.