

Ask HN: Why do many major sites fail W3C's markup validation service?  - nomolurcin

Pretty much every major site, including Google and Hacker News, does not pass.
======
dgunn
One reason my stuff usually fails is due to empty elements. For example:

    
    
      <div class="clear"></div>
    

in order to clear a float or something. There are better ways to do this but
nothing is more convenient than riddling your markup with non-semantic
garbage. If your website renders as expected in all major browsers, I say
don't worry about it.

Also, if it renders like crap in IEX, don't worry about it. IE users are used
to a horrible experience online. They see broken websites all the time and
just assume their computer has a virus. And it probably does. It's just not
causing their poor web experience.

------
ProblemFactory
Because it renders acceptably in common browsers, and that's what actual users
care about. If a website does not validate, only an extremely tiny subset of
users who test websites in validators is going to care about it.

Google's home page is now huge with the javascript and Google+ additions - but
it used to send invalid HTML missing end tags _on purpose_. Browsers still
render unclosed tags when reaching the end of the response, and therefore they
could send a smaller, faster HTML page by leaving off closing tags.

------
redegg
Modern browsers are tolerable with markup not being perfect.

With me, as long as it works, I don't care.

~~~
smartwater
The problem is that "as long as it works" is vague. All browsers? ALL? All
except IE7? IE6? iOS4?

------
mrkmcknz
I think that says more about the validation tool rather than the sites failing
it.

