美文网首页
html中table

html中table

作者: mimang | 来源:发表于2016-07-19 20:16 被阅读0次

table的一些属性
cellspacing单元格外边距 cellpadding单元格内边距

colspan=2,横向合并二个单元格被合并的单元格要删除

rowspan=2,纵向合并二个单元格被合并的单元格要删除

boder=“1”边框 caption表格标题在table与tr之间

thead 表格表头 tbody表格主体 tfoot表格页脚<table align="center" flot="left" border=1 width="500px" height="300px"style="color:blue;border-color:red;font-size:25px"cellspacing="0px"
cellpadding="30px" background="img/4.jpg">
<caption align="bottom">学生信息表</caption>

      <tr >
         <th colspan=2 >姓名</th>
        <th>年龄</th>
         <th>地址</th>
      </tr>
      <tr >
          <td >张三</td>
          <td >男</td>
          <td>25</td>
          <td rowspan=2>贵阳</td>
      </tr>
      <tr >
          <td >丽丽</td>
          <td >女</td>
          <td>20</td>
          
      </tr>
    </table>
E7C0D079-03FB-49F9-A412-0C0A99E65BD2.png

相关文章