

CSS
Presentation
•
Computers, Fun
•
Professional Development
•
Practice Problem
•
Medium
Robert Anderson
Used 44+ times
FREE Resource
9 Slides • 7 Questions
1
Intro to CSS
Cascading Style Sheets

2
What is CSS?
CSS is what we will use to make our webpages look nice and unique. They are separate files that we create that can be linked to our HTML to enhance the overall page.
3
Breakdown
Yellow: The first part is the "selector". This lets our HTML know what we are referring to.
Green: The next part is the entire declaration we are making.
Pink: Inside of the { } is where we will "declare" our style choices. "property: value;" pairs.
Orange: The first part of our pair is the "property" which states what type of style we are referring to.
Blue: The second part is the "value" which states the specific setting or numeric value we want to assign.
4
Multiple Choice
What does CSS stand for?
Cascadian Street Slang
Cruising Style Stools
Cascading Style Sheets
These are all wrong
5
Multiple Choice
Choose the correct property value pair.
propert; value;
property: value:
property: value
property: value;
6
Classes and ID's
A 'class' is an attribute assigned to an HTML element. It can be assigned to as many different elements as we would like. It is best used though for elements that are used for the same purpose.
An 'id' is also an attribute assigned to an HTML element. It is a specific and unique value that cannot be used anywhere else.
7
Selectors and Specificity
General element selectors can be used to style every element in your HTML that matches the selector (least specific)
When a "." starts the selector we are referring to a "class". So any element with an attribute of 'class=bill-images' will be assigned the same style as each other. (more specific)
When a "#" starts the selector we are referring to an "id". Each "id" is unique and can only be applied once. The one element with the attribute of 'id=quote' will be assigned the style choices declared
8
Multiple Choice
If I wanted to assign an attribute to style every single <p> tag what would work best?
p {color: blue;}
.p {color: blue;}
.paragraphs {color: blue;}
#paragraphs {color: blue;}
9
Multiple Choice
What selector is most specific?
h1 {height: 200px;}
#this-one {height: 200px;}
.theseOnes {height: 200px;}
* {height: 200px;}
10
3 Different ways to link CSS to HTML
1) In-line (not best practice, gets messy, hard to keep track of, not DRY)
What is DRY? (Don't Repeat Yourself) The practice of trying to write code that can be used and re-used multiple times instead of writing it over and over and over... and over and over.
2) Inside of the <style></style> element we can put inside of the <head></head> element in our HTML file. (Better than 'in-line', good for learning and working on small activities, still not best practice.)
3) Create a separate file with a ".css" extension and <link> the file to our HTML. (Best practice, keeps our HTML and CSS separate and keeps our code clean. We love clean code.)
11
CSS in-line
Written inside of the HTML element, only pertains to that specific element.
"style='property: value' "
12
CSS in <style> tags inside the <head>
Better than in-line. Can use general element selectors, class selectors, id's, and everything else in-between.
Still not best practice, can get messy and cumbersome as code grows. Too much going on in one place.
13
CSS <link>'ed!
Using a <link href="bill.css" rel="stylesheet" > inside of our <head> we can then write our CSS in a separate file to keep our code clean and easy to use.
This allows us to use our CSS on any HTML file we want to, by just adding a <link> in that HTML file. This helps with our practice of DRY coding.
14
Multiple Choice
Can you assign styles to a "class" with in-line CSS?
Yes
No
What is in-line styling?
Where am I?
15
Multiple Choice
How many elements can share the same "id"?
None, There can be only 1 element per "id".
Any element of the same type.
Any element with the same class.
All of them.
16
Multiple Choice
Can an HTML element have more than 1 "class"?
Yes
No
What's an element?
Where am I, and how did I get here?
Intro to CSS
Cascading Style Sheets

Show answer
Auto Play
Slide 1 / 16
SLIDE
Similar Resources on Wayground
10 questions
DISEÑO DE PÁGINAS WEB
Presentation
•
University
11 questions
Comparing numbers
Presentation
•
KG
11 questions
WSA's journey towards Sustainability
Presentation
•
Professional Development
11 questions
Valentine's Day
Presentation
•
8th Grade
12 questions
REGISTERED NURSE
Presentation
•
Professional Development
15 questions
10D Five ways to listen better
Presentation
•
Professional Development
11 questions
The Story: REFRESHER
Presentation
•
Professional Development
10 questions
Adult Learning Theory
Presentation
•
Professional Development
Popular Resources on Wayground
15 questions
Grade 3 Simulation Assessment 1
Quiz
•
3rd Grade
22 questions
HCS Grade 4 Simulation Assessment_1 2526sy
Quiz
•
4th Grade
16 questions
Grade 3 Simulation Assessment 2
Quiz
•
3rd Grade
19 questions
HCS Grade 5 Simulation Assessment_1 2526sy
Quiz
•
5th Grade
17 questions
HCS Grade 4 Simulation Assessment_2 2526sy
Quiz
•
4th Grade
20 questions
Equivalent Fractions
Quiz
•
3rd Grade
24 questions
HCS Grade 5 Simulation Assessment_2 2526sy
Quiz
•
5th Grade
20 questions
Math Review
Quiz
•
3rd Grade