I. List
ul
unordered list.
<body>
<ul>
<li>국어</li>
<li>영어</li>
<li>수학</li>
</ul>
</body>

ol
ordered list.
<body>
<ol>
<li>국어</li>
<li>영어</li>
<li>수학</li>
</ol>
</body>

type attribute를 사용해 다양한 형식의 ordered list를 만들 수 있다.
<body>
<ol type="A">
<li>국어</li>
<li>영어</li>
<li>수학</li>
</ol>
</body>

<body>
<ol type="a">
<li>국어</li>
<li>영어</li>
<li>수학</li>
</ol>
</body>

<body>
<ol type="I">
<li>국어</li>
<li>영어</li>
<li>수학</li>
</ol>
</body>

<body>
<ol type="i">
<li>국어</li>
<li>영어</li>
<li>수학</li>
</ol>
</body>

start attribute를 사용해 초기값을 설정할 수도 있다.
<body>
<ol start="3">
<li>국어</li>
<li>영어</li>
<li>수학</li>
</ol>
</body>

reversed attribute를 사용해 역순으로 나열할 수도 있다.
<body>
<ol start="5" reversed>
<li>국어</li>
<li>영어</li>
<li>수학</li>
</ol>
</body>

II. Table
- table 태그 : table을 만든다.
- tr 태그 : table row.
- th 태그 : table heading
- td 태그 : table data
<body>
<table>
<tr>
<th>이름</th>
<th>전공</th>
<th>학번</th>
</tr>
<tr>
<td>이이이</td>
<td>수학</td>
<td>9999-99998</td>
</tr>
<tr>
<td>김김김</td>
<td>통계</td>
<td>9999-99999</td>
</tr>
</table>
</body>

- rowspan attribute : 해당 셀이 차지하는 행의 개수
- colspan attribute : 해당 셀이 차지하는 열의 개수
<body>
<table>
<tr>
<th>이름</th>
<th colspan="2">전공</th>
</tr>
<tr>
<td>John</td>
<td rowspan="2">수학</td>
<td>물리</td>
</tr>
<tr>
<td>Jane</td>
<td>통계</td>
</tr>
</table>
</body>

Uploaded by N2T
'Frontend > HTML' 카테고리의 다른 글
07. HTML5 사용자 입력 (2) | 2022.08.27 |
---|---|
06. HTML5 이미지, 오디오, 비디오 (0) | 2022.08.27 |
04. HTML5 하이퍼링크 (0) | 2022.08.26 |
03. HTML5 텍스트 관련 태그 (0) | 2022.08.26 |
02. HTML5 기본 태그 (0) | 2022.08.26 |