Web Designers: How to validate CSS3 websites

Posted on Tuesday 8th Jun 2010 by James Kemp 4 Comments

Many web designers know that it is important to keep your code clean and valid, whether it is xHTML, CSS, or even Javascript and PHP. All of these languages are constantly updating, and sometimes it can be hard to keep track of how to validate them. Today I will discuss with you how you can validate for CSS3, what you need to add a link on your website, and a few things you should take note of.

CSS Validation

If any of you have validated before, then you will know to use W3C’s validation Service; the one I have linked to is specifically for CSS, but you can find the xHTML validation service on the same page.

By default, this service will validate for CSS level 2.1. This is fine for the majority of modern websites, but with CSS3 creeping from around the corner, it useful to stay validated. Fortunately, it is very easy to change the validation service to validate for CSS3.

  • Step 1: Type the address of your style-sheet into the text input field titled “Address:”.
  • Step 2: Click More Options, just below the input field.
  • Step 3: Select CSS Level 3 for the “Profile:” attribute.
  • Step 4: The other settings are fine, just click the “Check” button to see if your style-sheet is valid!

CSS3 Validation Service

If your style-sheet validates using this method then you can use the links it gives you to add a valid icon or text to the footer of your website. If not, you can fix the errors it shows and try again!

Things to Remember

A few things that are worth noting:

  • CSS3 is not a finished language as of yet, use it at your own risk!
  • -moz and -webkit rules are not currently valid CSS3 properties – they are browser specific (Firefox and Safari).

Conclusion

CSS3 is an exciting language and offers many possibilities, so make sure you validate your code and keep up to the standards that are put in place!

James Kemp

Nothing is known about James Kemp at this time.
This entry was posted in Tips For Web Designers and tagged , . Bookmark the permalink.

4 Responses to Web Designers: How to validate CSS3 websites

  1. Adam says:
    March 11, 2011 at 12:52 pm

    Quickly do it by linking your sites with: http://jigsaw.w3.org/css-validator/check/referer?profile=css3

  2. Dudley says:
    July 15, 2011 at 10:30 am

    This is all well and good, but doesn’t help with validating code that’s not been taken live yet? Is there any CSS3 validator out there that will allow us to drop our code in before going live?

  3. Delwin Campbell says:
    August 5, 2011 at 5:25 am

    Dudley: The W3 validator has both direct input and upload options, for code that hasn’t been pushed live yet. But I recommend living on the edge!

  4. Talasan Nicholson says:
    October 10, 2011 at 4:47 am

    Everytime I’m valid. EXCEPT for the important stuff like -moz, -webkit etc. C’mon validator! :)

Leave a Reply

Your email address will not be published. Required fields are marked *

*

You may use these HTML tags and attributes: <a href="" title=""> <abbr title=""> <acronym title=""> <b> <blockquote cite=""> <cite> <code> <del datetime=""> <em> <i> <q cite=""> <strike> <strong>