CSS vs HTML

Class Thursday, October 17, 2019

 Today’s Goals:

 Today’s featured website:

 Evaluate Your Inspirational Quote Graphics

  1. Look at your inspirational quote graphic  and evaluate it based upon the following criteria:
    Text readability
    Overall visual appearance
    Choice of background image to go along with quote
  2. Fill out this brief evaluation form  about your graphic

 Color in Web Design

  1. 2020 Trend Alert: Bold use of color and color psychology are among upcoming trends  for web design in 2020
  2. Read or listen to this article:
  3. Look at these infographics (source):
  4. Try these color tools (and pay attention to the color harmonies):
  5. Answer these questions: shorturl.at/bxAHO 

 Beginning CSS

  • What is CSS and why do we use it? HTML tells the browser what the content IS (link, paragraph, headline, etc.) while CSS STYLES the content (color, layout, positioning, font, etc.).
  • Let’s see the difference CSS makes even on a basic webpage. Go to http://medfordpublicschools.org/MHS%20Web%20Design/rainbow.html  and then let’s disable the CSS by using the Chrome developer tools to edit the HTML and comment out the CSS code. What is left?
  • Same HTML, different CSS: http://www.csszengarden.com /. Different CSS styles create entirely different webpages using the same HTML! Let’s also disable the CSS and see what’s left.
  • CSS syntax: Pointy brackets < > for style tags in head section, curly brackets { } in style sheet (next to the letter P on your keyboard; hit shift to make them) and semi-colons ; at the end of every line (next to the letter L, no shift key needed)
  • Let’s look at this example . Let’s change the background color to pink, the h1 color to purple, and the text-align to left. Let’s make the paragraph font-family Arial and the font-size 16px.
  • CSS vocabulary: let’s identify the selector, property, and value. What does CSS stand for? What is a style sheet?

 Fun with CSS colors

  • To choose colors with CSS, you can either use color names, RGB (red, green, blue) values, or hex color codes- check this out for examples. 
  • Hex value examples:
    • #ffffff (white) (full color)
    • #000000 (black) (no color)
    • #ff0000 (red)
    • #00ff00 (green)
    • #0000ff (blue)
  • Test your new color knowledge with this fun game!