Html table merging (rows, columns), html table
<Table> <tr> <td colspan = "2"> failed instance: </td> </tr> {% for ip, jieguo in reason. iteritems () %} <tr> <td colspan = "2" >{{ ip }}</td> </tr> {% for l, r in jieguo. iteritems () %} <tr> <td >{{ l }}</td> <td >{{ r }}</td> </tr >{% end %}{% end %} </table>
Column merge
Below is the row merge
<table> <tr> <th rowspan="2"></th> </tr></table>
How does html merge several columns in a row of a table?
Colspan = "2"
When colspan is equal to a few, it means merging several cells. This is the merging column;
Rowspan = "2": Merge rows;
They are written in the <td> label.
Example:
<Table width = "300" border = "0" cellspacing = "0" cellpadding = "0">
<Tr>
<Td> </td>
<Td> </td>
<Td colspan = "2"> </td>
<Td> </td>
</Tr>
<Tr>
<Td> </td>
<Td> </td>
<Td> </td>
<Td> </td>
<Td> </td>
</Tr>
<Tr>
<Td rowspan = "3"> </td>
<Td> </td>
<Td> </td>
<Td> </td>
<Td> </td>
</Tr>
<Tr>
<Td> </td>
<Td> </td>
<Td> </td>
<Td> </td>
</Tr>
<Tr>
<Td> </td>
<Td> </td>
<Td> </td>
<Td> </td>
</Tr>
</Table>
How to combine two columns in a table into one column in html?
Colspan or rowspan