
As coding is my specialty, the last post of this series hits close to home. Many clients and non-developers can often see that a website looks bad graphically, but (unless broken) they can not see how bad a website looks behind the scenes. I’m talking about HTML and CSS. These things are the skeleton and life blood of your site. It’s what makes the website look and act the way it does and it’s quite infuriating how the standards are often ignored and disregarded in coding. Some of the best looking sites have the sloppiest code out there. So what’s it to you and your site?
Having validated code ensures that you will have less errors in the future and makes it a lot easier to be cross browser compatible. This is important because there’s such a wide range of popular browsers today, therefor your site needs to work perfectly in all of them – or you risk losing your audience. clean code also means less load on your server, which means a faster website for your viewers.
There is some debate whether Google ranks sites with validated code over invalid sites. (Google itself doesn’t even validated) while it is sure that you aren’t penalized for it, it is certainly one of the tests Google runs in determining your rankings. The same goes for other search engines as well, and it is speculated Yahoo may even place more emphasis on validated code than Google. A company ran a test with 4 similar pages to see if Google placed the valid coder over the invalid code, (You can check out the test on here) and their findings suggested Google really does place an emphasis on both validated HTML and CSS. Of course content and keywords play the largest role, but this is one more important thing to push you to the top.
If you neglect basic alt tags and title tags, yes you can be sued. While this may be a slim chance, it’s still possible. Title and alt tags, while good for SEO, were created for accessibility reasons, so that the blind or impaired can navigate the web using a reader. Big businesses like Target (read story) have already been sued for this before.
Would you accept sloppy work from your housekeeper, banker or lawyer? If I threw your canned goods in the bag with the bread an eggs at the grocery store, would you accept that as a good job? Don’t accept sloppy work from your developer. You pay your developer good money to know what he or she is doing, so don’t accept jumbled code that doesn’t work in Firefox or code that doesn’t adhere to industry standards. A professional developer will take the extra time to make sure your code is clean and correct no matter what – that’s their job. Don’t be afraid to ask – or demand that your developer validate their code in one of the newest standards (1.0 Strict at least).
Here are some questions to ask your developer:
While you may get by on a sloppy coded site – it may even run perfect in browsers and rank well because of content – you’ll always be one step short of a great site. It’s one more small thing that sets the best sites apart from the good ones. It could be the difference between top 10 and #1. My biggest pet peeve is a lazy developer, and it should be yours too. Because we’re shooting for excellence, aren’t we?
It’s true. Generally people don’t appreciate code, never mind the validity of the code. That’s down to ignorance. So it’s our duty as code loving developers to educate clients about valid code and the benefits of it, during our development meetings and through blog posts such as this.
There are two things I really love about this post. The first, is the emphasis on the professionalism that valid code suggests. The second, is the questions that you should ask a developer. I just want to add that any developer worth their salt will not only be able to answer the question, but to explain the question in “non-geek” speak.
Just one point about the post I’m not sure I agree with and that is always validating as xhtml strict. There are some instances where this might not be possible. For example, if you embed a googlemap from the link on the googlemaps, you are actually embedding an iframe, which obviously wouldn’t validate in strict. You would need to use transitional (I’m not even mentioning frameset, it was a bad idea
). I think the developer should always aim to create a website which validates as strict (at least until html5 is released) but be aware that there are some situations where transitional may need to be used. And if the client asks about strict validation, again any developer worth their salt will be able to justify the reason for not doing so.
Overall great post. Keep it up
Good for you, Amber!
I thought I was the only one out here gnashing teeth when encountering all the bad invalid code online. I mean, how bad do you have to be to get even a transitional doctype wrong!!
There is really no such thing as “valid” transitional markup; it is an oxy-moron. “Valid” implies that the doctype used is compliant to the specification of the markup – in the case of any current XHTML (served using the text/html mime type) that would be HTML 4.01 strict.
Transitional doctypes were necessary to serve previously spec valid markup, for those of us who had hundreds or thousands pages using deprecated code, while we “transitioned” it over to spec compliant markup. It was supposed to be a temporary reprieve. It wasn’t meant to be a standalone “valid” version of the markup spec itself. Which is why it is a step backward.
Beginners still use the tag!!!! beginners still use !!!
Why? We can’t blame Microsoft anymore. It is an overall ignorance that’s even carried over into the books or online template/libraries.
And the state of things today only looks like it is getting worse. It seems as if all of the inroads made in standards compliance, usability, semantic tagging and valid markup over the last five years are being destroyed by the current inappropriate horrors perpetrated on the world as mangled Ajax.
It boggles the mind how the Ajax “faddies” can follow convoluted conditional programming logic, but can’t understand why two floated “divs” don’t inherit equal heights or why they can’t auto center a block using position:absolute.
Dave
Yea I always validated in XHTML 1.0 Strict unless it’s WordPress (I don’t want to go through their mountains of code) whereas I use 1.0 Transitional. Sometimes it’s hard to keep up though, as you never know when they come out with a new validation…wish they would pick a way and stick to it