Hi, What is the main benefit of W3 validation actually? If a site doesn't have w3 validation, what problems that may occur? Thanks...
The validation is not very important, but if your code is valid then you will be sure that search engines "understands" your sites. And second - you will make an good impression on your visitors.
If your site is not valid, then you have errors in your markup. Errors in anything are never good. Browsers will do their best to render what you meant but you are relying on all browsers to think alike and read your mind. Also not a good thing. Valid or not is never a question to ask.
Don't always go by validations though. Sometimes they say things are 'errors' but when in fact they are not. Just a tip.
In addition to the above, I just want to add that the W3C sets the "standards" for the Web. So, if your site isn't validating, that means you're not doing something right. (Obviously. : ) Making sure your site validates holds you to a higher standard of coding, I think. (Of course, you can still do things that don't make "clean code", (using extra divs, etc.), and it could still validate. But I hope you know what I was getting at.) Fixing validation errors can also save you headaches with layout, (as mentioned). Plus, doesn't it feel good to see that green bar saying your site's valid? ; )
Valid markup means you ACTUALLY HAVE HTML (and/or XHTML) and not complete ****ing gibberish. When you have gibberish you are NOT relying on the proper behavior of the markup but the automatic error correction that has given web developers a sleazeball 'free ride' for the better part of a decade and a half. Given that until the past three or four years browser manufacturers have done little in the way of being on the same page when it comes to the handling of errors, you are more likely to see your pages break in standards compliant browsers or new versions of non-compliant browsers like IE. (need that IE6 or IE7 specific hack? Hacking JUST for IE8 beta already? Guess what!) It is not the be all end all solution to problems, as rubbish code is rubbish code whether it validates or not - but invalid code is ALWAYS rubbish. As our resident stooges fan said, "Valid or not is never a question to ask." I've said it at least four dozen times on these forums, if it doesn't validate, it's NOT HTML, it's gibberish - and you are pretty much hoping that all browsers might actually interpret that gibberish the same way... good luck with that.