WEB/html,CSS
[html] div블럭 태그와 span 인라인태그
자바칩 프라푸치노
2021. 4. 4. 15:18
div태그와 span태그에 대해 간단하게 알아보자
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
|
<!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>Document</title>
</head>
<body>
<!-- 개행을 하지 않아도 블럭 형식으로 분리가 된다 -->
<div>block1</div>
<div>block2</div>
<div>block3</div>
<div>block4</div>
<div>block5</div>
<br>
<!-- 라인으로 쭉 이어진다 -->
<span>inline1</span>
<span>inline2</span>
<span>inline3</span>
<span>inline4</span>
</body>
</html>
|
cs |
결과

728x90