본문 바로가기

HTML/HTML 기초

[HTML] table에서 thead, tbody, tfoot 사용해 보기 - 2

<!DOCTYPE html>
<html lang="ko">

<head>
    <meta charset="UTF-8">
    <meta name="viewport" content="width=device-width, initial-scale=1.0">
    <title>Document</title>
</head>

<body>
    <table border="1">
        <caption>
            <string>컴퓨터 주변 기기</string>
        </caption>
        <thead>
            <tr>
                <th>주변 기기</th>
                <th>이미지</th>
                <th>주변 기기</th>
                <th>이미지</th>
            </tr>
        </thead>
        <tbody>
            <tr>
                <th>마우스</th>
                <th><img src="../images/mouse.jpg" width="200" height="150"></th>
                <th>프린터</th>
                <th><img src="../images/printer.jpg" alt="keyboard" width="200" height="150"></th>
            </tr>
            <tr style="text-align: left;">
                <th colspan="4"><i>신청 연락처 02-123-4567</i></th>
            </tr>
        </tbody>

    </table>
</body>

</html>

728x90
반응형