Nested Table

A nested table is a table inside another table. This is useful for creating complex layouts like invoices, reports, or dashboards.

<table border="1" cellpadding="5" cellspacing="0">
    <tr>
        <th>Main Table - Column 1</th>
        <th>Main Table - Column 2</th>
    </tr>
    <tr>
        <td>Row 1, Cell 1</td>
        <td>
            <table border="1" cellpadding="5" cellspacing="0">
                <tr>
                    <th>Nested Table - Col 1</th>
                    <th>Nested Table - Col 2</th>
                </tr>
                <tr>
                    <td>Nested Row 1</td>
                    <td>Nested Row 1</td>
                </tr>
                <tr>
                    <td>Nested Row 2</td>
                    <td>Nested Row 2</td>
                </tr>
            </table>
        </td>
    </tr>
</table>


Qus. 1 : Is it possible to insert a table within another table?

  1. Yes, but there must be exactly 2 rows and 2 columns in first table.
  2. Yes, table can be inserted into cell of another table.
  3. Yes, but there must be no border in other table.
  4. No, it’s not possible.

Programs

html program to display a table with 5 rows and 4 columns. Provide appropriate heading to the form

View Solution


HTML Page to display the following table

View Solution


HTML Code design Time Table using rowspan and colspan

View Solution


HTML Code design complex Time Table using rowspan and colspan

View Solution


HTML Code to Design Basic Table

View Solution


html code to design the complex table with rowspan and colspan

View Solution


html table for Indian Tourist Spots

View Solution


Latest Current Affairs 2025 Online Exam Quiz for One day Exam Online Typing Test CCC Online Test Python Programming Tutorials Best Computer Training Institute in Prayagraj (Allahabad) Online MBA 2 years Online MCA Online BCA Best Website and Software Company in Allahabad