表格属性 难点

203 阅读1分钟
	<!-- 表格属性 -->				          <!-- --- cellpadding 内容与边框的距离 -->
<table width="500" height="300" border="1" cellspacing="0" cellpadding="0" align="center">
<!-- 表格标签 是一个四方块盒子 -->         <!-- ---cellspacing 单元格与边框的距离 -->
<caption>俺是表格大标题</caption>

<thead>   <!-- 表格的头部 -->
<tr>    <!--  行标签 -->
		<th>姓名</th>      <!-- 表头标签 -->
		<th>性别</th>
		<th>年龄</th>
</tr>
</thead>
<tbody>     <!-- 表格的身体 -->
<tr>
		<td>马云</td>     <!-- 单元格标签 -->
		<td>男</td>
		<td rowspan="2"> 55 </td> <!-- 跨行合并单元格 -->
</tr>
<tr>
		<td>马化腾</td>
		<td>男</td>
		
</tr>
<tr>
		<td>我</td>
		<td colspan="2">合并后的单元格</td><!-- 跨列合并单元格 -->
</tr>
</tbody>
</table>