-
Notifications
You must be signed in to change notification settings - Fork 0
/
tut24-Display.html
80 lines (67 loc) · 2.45 KB
/
tut24-Display.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
<!DOCTYPE html>
<html lang="en">
<head>
<meta charset="UTF-8">
<meta http-equiv="X-UA-Compatible" content="IE=edge">
<meta name="viewport" content="width=device-width, initial-scale=1.0">
<title>Display properties</title>
<style>
* {
box-sizing: border-box;
}
header {
margin: auto;
border: 4px groove black;
}
#img {
display: block;
margin: auto;
width: 50px;
height: 50px;
}
h3 {
text-align: center;
}
.con {
margin: auto;
}
.first {
border: 4px solid black;
margin: 10px 0px;
padding: 10px;
width: 33%;
display: inline-block;
}
</style>
</head>
<body>
<header>
<img id="img" src="/mike.jpg" alt="error loading">
<h3 class="Heading">Display Properties</h3>
</header>
<div class="con">
<div class="first">
<h5>Paragraph</h5>
Lorem ipsum dolor sit amet consectetur adipisicing elit. Illo maiores praesentium laboriosam tenetur laborum
nisi, a cum corporis provident beatae esse veritatis temporibus cupiditate atque impedit natus qui sunt
vero? Impedit itaque minima pariatur optio magni deserunt delectus, possimus corrupti!
</div>
<div class="first">
<h5>Paragraph</h5>
Lorem ipsum dolor sit amet consectetur adipisicing elit. Illo maiores praesentium laboriosam tenetur laborum
nisi, a cum corporis provident beatae esse veritatis temporibus cupiditate atque impedit natus qui sunt
vero? Impedit itaque minima pariatur optio magni deserunt delectus, possimus corrupti!
</div>
<div class="first">
<h5>Paragraph</h5>
Lorem ipsum dolor sit amet consectetur adipisicing elit. Illo maiores praesentium laboriosam tenetur laborum
nisi, a cum corporis provident beatae esse veritatis temporibus cupiditate atque impedit natus qui sunt
vero? Impedit itaque minima pariatur optio magni deserunt delectus, possimus corrupti!
</div>
</body>
</html>
<!--
inline: takes only as much space as the content needs. cannot give width.
block: takes the whole width, but height depends on the content.
inline-block: same as inline, but we can provide width, which is not possible in inline.
-->