tags:

views:

49

answers:

3

What type of XHTML and CSS validations errors can be avoided? which would not harmful today and tomorrow (if we do not touch xhtml, css )?

I mean errors which will not create any problem on future upgrade of browser, css and html version? they just show as an error today?

I think one thing I know is Vendor extensions. Are there any other errors/warnings which will not create any bad effect for user and developer?

If I'm making a site and i get many errors should i try to give time to solve every error? if i will try to solve all error then i will have to use javascript on some instances in place of css

A: 

Each browser will render and parse XHTML and css differently. Even if it works now it might not work tomorrow.

The only safe answer is "none". The best guarantee you have for future compatibility wth all browsers is stick to the standard and have fully validated xhtml and css.

DanDan
While certainly correct, there are plenty of detailed rules in place about how to deal with erroneous markup. For fully conforming browsers (of which there are none, afaik) the results should be identical.
Joey
I still don't understand why CSS validation is necessary. If your CSS doesn't work you should be able to tell by just looking at your page. Yes you should check for invalid markup (missed semicolons, unclosed properties {}) but other than that you'll get into trouble for using CSS hacks etc.. (which you should avoid anyway). Some new CSS3 properties won't validate yet but they might improve the user experience. To me - CSS validation is pointless.
Marko
+2  A: 

The XHTML and CSS validators will validate against the corresponding specifications of the W3C standards. Ignoring these mean that your page(s) are deviating from those standards.

Web browsers aim to implement these standards, so ignoring a warning is likely to cause issues on at least some browsers. Therefore, you cannot ignore any warning that the validators give.

Also, having XHTML and CSS conformant web pages is not guaranteed to work on all browsers and be compatible with them as the browsers may implement something differently or incorrectly.

Having conformant pages is still a good thing, as most browsers are (for the most part) conformant and having more conformant pages helps put the ownership on the browser implementers. That is, you (as a web page author) need only concern yourself with being standard compliant. If a browser can't handle that, the issue is with the browser, not the web page author.

If you want to be compatible with a large number of browsers, start with the valid conformant page and then add the minimum needed to get it working on other non-conformant browsers. Doing it this way is a lot easier than starting with a non-conformant page and trying to make that work on most browsers.

reece
+1  A: 

You should try to avoid all parse errors. If in doubt, try the validator.w3.org and use the html tidy function to clean up the code.

MRAISKY