-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathfloats.html
More file actions
74 lines (62 loc) · 958 Bytes
/
floats.html
File metadata and controls
74 lines (62 loc) · 958 Bytes
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
<!DOCTYPE html>
<html>
<head>
<title>Using Floats</title>
<style>
body{
color: #fff;
font-family: 'Nunito Semibold';
text-align: center;
line-height: 3em;
}
#content{
max-width: 960px;
margin: 0 auto;
}
header{
background: #3bbced;
height: 50px;
}
main{
float: right;
width: 60%;
background: #e82b69;
height: 400px;
}
aside{
background: #fac24a;
height: 200px;
}
nav{
background: #8ae348;
height: 200px;
}
footer{
background: #a56dda;
height: 100px;
}
#sidebar{
float: left;
width: 40%;
}
#middle:after{
content: '';
display: block;
clear: both;
}
</style>
</head>
<body>
<div id="content">
<header>Header</header>
<div id="middle"><!-- extra markup -->
<main>Main</main>
<div id="sidebar"><!-- extra markup -->
<aside>Aside</aside>
<nav>Nav</nav>
</div>
</div>
<footer>Footer</footer>
</div>
</body>
</html>