This is an old revision of the document!
CSS Cheat Sheet
This is a summarized form of the CSS Tutorial.
For reference this is the CSS2 Specification .
What is CSS
- CSS stands for Cascading Style Sheets.
- Styles define how to display HTML elements. Style sheets are collections of styles.
- Multiple style sheets will cascade into a single style definition.
- Styles can be specified inside an HTML element, inside the <head> element or in an external CSS file - in that order of priority.
- CSS syntax is made up of three parts - selector {property: value}.
- Multiple property-value pairs may be separated by semi-colons.
- Multiple selectors must be separated by commas
- Values must be quoted if they are multiple words
- A simple example
h1,h2,h3 { text-align: center; color: black; font-family: "sans serif" }