Class 5 notes

My reading journal for Code Fellows

Class 5 notes

Design web pages with CSS

How to add CSS

  1. external CSS
  1. internal CSS
  1. inline CSS

Multiple Style Sheets

cascading order

  1. Inline style (inside an HTML element)
  2. External and internal style sheets (in the head section)
  3. Browser default So, an inline style has the highest priority, and will override external and internal styles and browser defaults.

CSS Syntax

-color: color|initial|inherant;

property values

examples

  1. Set the text color with a HEX value: body {color: #92a8d1;}

  2. Set the text color with an RGB value: body {color: rgb(201, 76, 76);}

  3. Set the text color with an RGBA value: body {color: rgba(201, 76, 76, 0.6);}

  4. Set the text color with a HSLA value: body {color: hsla(89, 43%, 51%, 0.6);}

CSS Reference

link to long list of references