Forum Moderators: Robert Charlton & goodroi
I was just going trough my high level requirements and started to wonder if I should put "Site should W3C HTML and CSS validate"
Site MUST validate...
Is a realistic requirement?
Is it worth the extra effort and cost if possible?
I've never understood this particular debate. All code should be valid - period.
The easiest way to maintain tight control over code is to write it by hand, that's probably why so few pages validate these days. Too many developers are relying on WYSIWYG editors.
While your site may appear correctly in some browsers even if your HTML is not valid, there's no guarantee that it will appear correctly in all browsers - or in all future browsers. The best way to make sure that your page looks the same in all browsers is to write your page using valid HTML and CSS, and then test it in as many browsers as possible. Clean, valid HTML is a good insurance policy, and using CSS separates presentation from content, and can help pages render and load faster. Validation tools, such as the free online HTML and CSS validators provided by the W3 Consortium, are useful for checking your site, and tools such as HTML Tidy can help you quickly and easily clean up your code. (Although we do recommend using valid HTML, it's not likely to be a factor in how Google crawls and indexes your site.)
easier to spider, less chance of breaking down the road, chance of better rankings
Why should your code validate? As long as it renders well in the top browsers who cares. I don't.
As long as it renders well in the top browsers who cares. I don't.
Google, Bing and Yahoo don't care if my pages validate.
And 99% of my viewers don't even know what validation is about.
WHY should my pages validate if all the main browsers (maybe even 100% of browsers) show my pages as I want.
The search for perfection detracts from the main objective of a website which is to give users the information they want in an attractive format.
As long as it renders well in the top browsers who cares. I don't.
Do you have the same cavalier attitude towards your content: not fixing spelling and grammar errors, not fixing broken links, etc?
But I do care about understanding any error that shows up. Most of them I fix, but once in a while I just ignore one because I know why it's there.
I do too and I think this is the pragmatic approach.
having a valid DOM is very important when your site is a "complex web 2.0 style site" and you're doing ajaxian things to it.
None of you purists have explained why Webmasterworld does not validate, Google does not validate, Bing, Yahoo, Microsoft, Amazon, YouTube, Facebook, Wikipedia and a host of other cutting edge sites don't validate and why it does not seem to do them any harm?
And I have seen sites scoring high for keywords because they use broken HTML on purpose, to fool spiders.
Before you make a blanket statement like that, you should double check those sites for validation.P1R I did check all their home pages. They didn't validate and they still don't validate. Remember you are the one who said, "All code should be valid - period" so getting close to validation is still a failure.
You cannot continue to use this as an argument for writing broken code.I didn't say that and I don't deliberately write broken code. I did say that we should all aim for 100% valid markup but IMO it is just not as important as some of you are making out.
WebmasterWorld? Let's not go there. It pains me to see my favorite hangout not valid.Why does it pain you? Do you see any performance issues related to the fact that it does not validate and does it in any way spoil your user experience?
Google does validate. Not all pages but I've watched as they've slowly changed to an HTML5 DOCTYPE and are cleaning up a bulk of the markup errors. I've been tracking this since 2009 September.
Oh come on! That's even a lamer excuse than the other one being used. That is total FUD!
Validating HTML is easy but if you are running external scripts, affiliate schemes or even Adsense then this may well cause your website to fail.
(The good old BBC is one of the few popular websites that does manage to validate incidentally.)
I disagree! Why should your code validate? As long as it renders well in the top browsers who cares. I don't.