This repository has been archived by the owner on Sep 22, 2023. It is now read-only.
-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathcss-basics.html
95 lines (80 loc) · 3.07 KB
/
css-basics.html
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
<html>
<head>
<title>LUNCHTML 2.0 - Review: MVP Tags</title>
<link rel="stylesheet" type="text/css" href="style-review.css" />
<link rel="stylesheet" type="text/css" href="style-css.css" />
<link href='http://fonts.googleapis.com/css?family=Ribeye+Marrow' rel='stylesheet' type='text/css'>
</head>
<body>
<h1>CSS Basics</h1>
<a name="div"><br/><br/><br/><h2>divs & spans</h2>
<span id="label-span">HTML:</span>
<pre>
Watch this: <div id="mydiv">Hello, world.</div>
Watch this: <span id="myspan">Hello, world.</span>
</pre>
<span id="label-span">RESULT:</span> Watch this:<div id="mydiv">Hello, world.</div>
Watch this: <span id="myspan">Hello, world.</span>
<div class="nav">
<a href="#div">divs & spans</a> |
<a href="#inline">inline styles</a> |
<a href="#style">embedded styles (<style> tag)</a> |
<a href="#sheet">external styles (<link> tag)</a>
</div>
<a name="inline"><br/><br/><br/><h2>inline css</h2>
<span id="label-span">HTML:</span>
<pre>
Watch this: <span style="font-weight:bold;color:red;font-style:italic;">Hello, world.</span>
</pre>
<span id="label-span">RESULT:</span> Watch this: <span style="font-weight:bold;color:red;font-style:italic;">Hello, world.</span>
<div class="nav">
<a href="#div">divs & spans</a> |
<a href="#inline">inline styles</a> |
<a href="#style">embedded styles (<style> tag)</a> |
<a href="#sheet">external styles (<link> tag)</a>
</div>
<a name="style"><br/><br/><br/><h2>inline css</h2>
<span id="label-span">HTML:</span>
<pre>
<style type="text/css">
#myspan2 {
font-weight: bold;
color: green;
font-style: italic;
}
</style>
Watch this: <span id="myspan2">Hello, world.</span>
</pre>
<span id="label-span">RESULT:</span>
<style type="text/css">
#myspan2 {font-weight:bold;color:green;font-style:italic;}
</style>
Watch this: <span id="myspan2">Hello, world.</span>
<div class="nav">
<a href="#div">divs & spans</a> |
<a href="#inline">inline styles</a> |
<a href="#style">embedded styles (<style> tag)</a> |
<a href="#sheet">external styles (<link> tag)</a>
</div>
<a name="sheet"><br/><br/><br/><h2>inline css</h2>
<span id="label-span">HTML:</span>
<pre>
<link rel="stylesheet" type="text/css" href="style-css-sheet-happens.css" />
Watch this: <span id="myspan3">Hello, world.</span>
</pre>
<span id="label-span">RESULT:</span>
<link rel="stylesheet" type="text/css" href="style-css-sheet-happens.css" />
Watch this: <span id="myspan3">Hello, world.</span>
<br/><br/>
<span id="label-span">THE SHEET:</span>
<pre>
#myspan3 {font-weight:bold;font-style:italic;color:blue;font-size:28px;}
</pre>
<div class="nav">
<a href="#div">divs & spans</a> |
<a href="#inline">inline styles</a> |
<a href="#style">embedded styles (<style> tag)</a> |
<a href="#sheet">external styles (<link> tag)</a>
</div>
</body>
</html>