Search over 1.4 million articles by over 600 experts
  1. Home
  2. Computing & Technology
  3. Web Design / HTML

More from About.com

Browse Topics A-Z

Basics of CSS

By Jennifer Kyrnin, About.com

What is CSS:

CSS is an abbreviation for the term "Cascading Style Sheets". CSS was first developed in 1997 as a way to separate the way a Web page looked from the content and behavior. CSS defines how to display the content contained in markup and is stored in style sheets.

What is the Cascade:

In CSS the cascade is like a waterfall, as the user agent encounters style rules it applies them one after the other. The order of styles is:

  1. browser defaults
  2. external style sheets
  3. internal style sheets
  4. inline styles
  5. the more specific style selector will take precedence
    • h2 is more specific than the universal selector
    • h2.class is more specific than h2
    • h2.id is more specific than h2.class
Separate Style from Structure:

CSS was generated to separate the look and feel or style of Web pages from the XHTML markup or structure of the pages.

Three Types of CSS Styles:

There are three ways you can add styles to your Web pages:

  • inline styles
  • embedded styles
  • external styles
How to Edit a Style Sheet:

Some people use a CSS style sheet editor.

But it's easy to edit a style sheet using just a text editor.

  1. Home
  2. Computing & Technology
  3. Web Design / HTML
  4. CSS
  5. Beginning CSS
  6. CSS Tutorial
  7. Start Here to Learn CSS - Basics of CSS - Learn CSS - Beginning CSS

©2008 About.com, a part of The New York Times Company.

All rights reserved.