Create a nested table in HTML and CSS
Description
The following code shows how to create a nested table.
Example
<html>
<body>
<!--from w ww.java 2s. co m-->
<table border="1">
<tr>
<th></th>
<th>A</th>
<th>B</th>
</tr>
<tr>
<th>Saturday</th>
<td>Database</td>
<td>XML</td>
</tr>
<tr>
<th>Sunday</th>
<td>Java</td>
<td>
<table>
<tr>
<th>Group 1</th>
<th>Group 2</th>
</tr>
<tr>
<td>HTML</td>
<td>CSS</td>
</tr>
</table>
</td>
</tr>
</table>
</body>
</html>
The code above generates the following result.
HTML CSS Tutorial Table Structure
Add table caption to a table in HTML and CS...
Add table cell(table data) to a table in HT...
Add table footer to a table in HTML and CSS
Add table header to a table in HTML and CSS
Add vertical header or row header to a tabl...
Column groups with col element in HTML and ...
Create a Table with Longer Cell Content in ...
Float table around text in HTML and CSS
Group column using colgroup in HTML and CSS
Span Cell to two rows in HTML and CSS
Span a table cell to Multiple Columns in HT...
Add table caption to a table in HTML and CS...
Add table cell(table data) to a table in HT...
Add table footer to a table in HTML and CSS
Add table header to a table in HTML and CSS
Add vertical header or row header to a tabl...
Column groups with col element in HTML and ...
Create a Table with Longer Cell Content in ...
Create a nested table in HTML and CSS
Create a table with columns and rows in HTM...Float table around text in HTML and CSS
Group column using colgroup in HTML and CSS
Span Cell to two rows in HTML and CSS
Span a table cell to Multiple Columns in HT...