HTML টেবিল কলাম উপাদান (The HTML Table Column element)

<col>: HTML টেবিল কলাম উপাদান (The HTML Table Column element)। একটি টেবিল এর মধ্যে দুটি রো কিংবা কালাম কে এক সঙ্গে মারজ করতে <col>: HTML টেবিল কলাম উপাদান (The HTML Table Column element) ব্যবহার করা হয়ে থাকে। নিচে উদাহরন দেওয়া হল।

Example:

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

<head>
    <meta charset="UTF-8">
    <meta name="viewport" content="width=device-width, initial-scale=1.0">
    <title>HTML MASTER JHUTANDA</title>
    <!--https://jhutanda.com-->
    <!--https://github.com/jhutanda-->
</head>

<body>
    <table border="1">
        <colgroup>
            <col span="2" style="background-color: aqua;">
            <col span="1" style="background-color: red;">
            <col span="2" style="background-color: yellow;">

            <!-- there is a difference between "<col span> and "<colspan>  see the bellow example-->

        </colgroup>
        <tr>
            <th>head</th>
            <th>head</th>
            <th>head</th>
            <!-- you can use it <col/> tag and see the result-->
            <col/>

        </tr>
        <tr>
            <td>1</td>
            <td>1</td>
            <td>1</td>
            <td>1</td>
            <td>1</td>
        </tr>
        <tr>
            <td>2</td>
            <td>2</td>
            <td>2</td>
            <td>2</td>
            <td>2</td>
        </tr>
        <tr>
            <td>3</td>
            <td>3</td>
            <td>3</td>
            <td>3</td>
            <td>3</td>
        </tr>
        <!-- example  of html <colspan> tag -->
        <tr>
            <td colspan="4">Total</td>
            <td>number</td>
        </tr>

    </table>

</body>

</html>

Scroll to Top