您现在的位置: 万盛学电脑网 >> 程序编程 >> 网页制作 >> Html5 >> 正文

html表格跨列代码介绍

作者:佚名    责任编辑:admin    更新时间:2022-06-22

欢迎大家在这里学习html表格跨列!下面是我们给大家整理出来的精彩内容。希望大家在这里学习!

<html>

<body>

<h4>横跨两列的单元格:</h4>

<table border="1">

<tr>

  <th>姓名</th>

  <th colspan="2">电话</th>

</tr>

<tr>

  <td>Bill Gates</td>

  <td>555 77 854</td>

  <td>555 77 855</td>

</tr>

</table>

<h4>横跨两行的单元格:</h4>

<table border="1">

<tr>

  <th>姓名</th>

  <td>Bill Gates</td>

</tr>

<tr>

  <th rowspan="2">电话</th>

  <td>555 77 854</td>

</tr>

<tr>

  <td>555 77 855</td>

</tr>

</table>

</body>

</html>

好了,html表格跨列内容就给大家介绍到这里了。希望大家继续关注我们的网站!

相关推荐:

简单的html表格代码