Web Application Development
CSS
CSS
3
9/24/2020
CSS
4
9/24/2020
CSS
5
9/24/2020
Declaration
CSS
6
9/24/2020
CSS Example
7
9/24/2020
CSS
8
9/24/2020
CSS
9
9/24/2020
CSS
10
9/24/2020
CSS
11
9/24/2020
CSS
12
9/24/2020
CSS
13
9/24/2020
CSS
14
9/24/2020
CSS
15
9/24/2020
CSS
16
9/24/2020
CSS
17
9/24/2020
CSS
18
9/24/2020
CSS
19
9/24/2020
CSS
20
9/24/2020
CSS
21
9/24/2020
CSS
22
9/24/2020
CSS
23
9/24/2020
CSS
24
9/24/2020
CSS
25
9/24/2020
CSS
26
9/24/2020
CSS
27
9/24/2020
CSS
28
9/24/2020
CSS
29
9/24/2020
Selector | Example | Example description |
element element | div p | Selects all <p> elements inside <div> elements |
element>element | div > p | Selects all <p> elements where the parent is a <div> element |
element+element | div + p | Selects all <p> elements that are placed immediately after <div> elements |
element1~element2 | p ~ ul | Selects every <ul> element that are preceded by a <p> element |
CSS
selector : pseudo-class {� property:value;�}
30
9/24/2020
CSS
31
9/24/2020
CSS
32
9/24/2020
CSS
33
9/24/2020
Summary: CSS selectors
34
9/24/2020
Summary: CSS selectors
35
9/24/2020
Rules for Applying CSS
36
9/24/2020
37
9/24/2020
38
9/24/2020
SPECIFICITY
If one selector is more specific than the others, the more specific rule will take precedence over more general ones. In this
example:
h1 is more specific than *
p b is more specific than p
p#intro is more specific than p
39
9/24/2020
IMPORTANT
You can add !important after
any property value to indicate
that it should be considered
more important than other rules that apply to the same element.
Borders
40
9/24/2020
Borders
41
9/24/2020
List: Example
42
9/24/2020
Page Padding
43
9/24/2020
Page Padding
44
9/24/2020
CSS
45
9/24/2020
CSS
46
9/24/2020
LAYOUT ELEMENTS
47
9/24/2020
Page Layout
48
9/24/2020
Output
49
9/24/2020
List Property
none
50
9/24/2020
List Property
51
9/24/2020
52
9/24/2020
Home Task
53
9/24/2020
Home Task
54
9/24/2020
Home Task
55
9/24/2020