Difference between revisions of "Cascade Style Sheets"
Jump to navigation
Jump to search
Back to Web Development
Line 1: | Line 1: | ||
== Cascade Style Sheets (CSS) == | == Cascade Style Sheets (CSS) == | ||
=== Helpful links === | |||
[http://www.w3.org/Style/CSS/ Cascading Style Sheets home page] | [http://www.w3.org/Style/CSS/ Cascading Style Sheets home page] | ||
[http://www.w3.org/Style/CSS/current-work Cascading Style Sheets Current Work] | [http://www.w3.org/Style/CSS/current-work Cascading Style Sheets Current Work] | ||
[http://www.w3.org/TR/CSS21/ Cascading Style Sheets Level 2 Revision 1 (CSS 2.1) Specification] | [http://www.w3.org/TR/CSS21/ Cascading Style Sheets Level 2 Revision 1 (CSS 2.1) Specification] | ||
[http://www.w3.org/TR/REC-CSS2/ Cascading Style Sheets, level 2 CSS2 Specification] | [http://www.w3.org/TR/REC-CSS2/ Cascading Style Sheets, level 2 CSS2 Specification] | ||
[http://www.w3.org/TR/REC-CSS1 Cascading Style Sheets, level 1 CSS1 Specification] | [http://www.w3.org/TR/REC-CSS1 Cascading Style Sheets, level 1 CSS1 Specification] | ||
Revision as of 19:30, 19 May 2008
Cascade Style Sheets (CSS)
Helpful links
Cascading Style Sheets home page
Cascading Style Sheets Current Work
Cascading Style Sheets Level 2 Revision 1 (CSS 2.1) Specification
Cascading Style Sheets, level 2 CSS2 Specification
Cascading Style Sheets, level 1 CSS1 Specification
A CSS is made up of two parts: the selector and declaration. The selector states which tag the rule applies. The declaration stats what happens when the rule is applied.
The declaration is made up of two elements: a property and value. A declaration must end with a semicolon.
Multiple declarations can be contained in a single rule.
Multiple selectors can be contained in a single rule. A comma must be used after each selector except the last.
h1, h2, h3 {color:red; font-weight:bold;}
Multiple rules can be applied to the same selector.
h1, h2, h3 {color:red; font-weight:bold;} h3 {font-style:italic;}