Question:
Validating CSS and HTML?
MaSx
2013-11-18 11:15:37 UTC
Can you validate CSS files, in the same way you validate HTML and XHTML files?
Six answers:
Leo D
2013-11-18 11:40:32 UTC
Yes, you can validate both in the official W3C website:

- HTML and more: http://validator.w3.org/

- CSS: http://jigsaw.w3.org/css-validator/

- Also RDF: http://www.w3.org/RDF/Validator/



For HTML HTML5 though, you might get best results at http://html5.validator.nu/ because it's usually updated as the standard is. I believe this might be official for the WHATWG standard of HTML5. It also has a few more options.



The HTML validator is for HTML 2 to HTML5 (including XHTML 1, 1.1, and various profiles; HTML5 is a little experimental though, but it's probably the best for XHTML5.), RDFa, any custom XML* language with an embedded DTD, MathML, SVG and SMIL. The CSS validator goes up to level 2 and some of level 3.



*(possibly any custom SGML language with an embedded DTD and SGML prologue. I remember playing around with this, but I think I barely scratched the surface with SGML.)



Sometimes the validator for HTML can be very slow though. It wasn't always like that and it might've gotten better since I last checked. I haven't been using it to check CSS as often as I used to, so I can't speak on how well it's doing now. On its bad days, you might try the validator at http://www.cssportal.com/css-validator/
Manikandan
2013-11-20 03:14:44 UTC
Validate your HTML, CSS, and other Web file types with these HTML validators. There is an HTML validator, a CSS validator, an XHTML validator, an RSS and Atom validator, and a P3P Validator. These validators are easy to use, just put in the URL of HTML file and click on the Validate button.
rob
2013-11-18 11:57:41 UTC
Validate your HTML, CSS, and other Web file types with these HTML validators. There is an HTML validator, a CSS validator, an XHTML validator, an RSS and Atom validator, and a P3P Validator. These validators are easy to use, just put in the URL of HTML file and click on the Validate button.



Once you've got valid code, you should use the Accessibility validator to make sure your page is accessible to search engines and people with disabilities.
Common
2013-11-18 11:38:42 UTC
Yes we do validate CSS files and we use the following tool fro validating cascading style sheets

http://jigsaw.w3.org/css-validator/‎



It is the same as we validate HTML and xHTML file
Albert W
2013-11-18 11:51:50 UTC
Hi There,



I use Coffeecup free HTML editor for my pages and it has an easy ( and quick ) way for validating HTML and CSS code.



All you need to do is load your page in Coffeecup and there is a tab at the top with the option for validating everything.

It is accessed from the "Document" tab and is at the bottom of the list.



Hope this helps,

Al
Md Monoar
2015-07-30 08:49:16 UTC
Good question but ans is not enough.


This content was originally posted on Y! Answers, a Q&A website that shut down in 2021.
Loading...