时间:2021-07-01 10:21:17 帮助过:116人阅读

HTML可以通过为表格添加border属性来添加边框。推荐学习:html教程
示例:
<!DOCTYPE html>
<html>
<head>
<meta http-equiv="Content-Type" content="text/html; charset=utf-8"/>
</head>
<body>
<table width="400" border="1" cellspacing="0" cellpadding="0">
<tr>
<td >示例</td>
<td >网址</td>
<td >示例</td>
</tr>
<tr>
<td>示例</td>
<td>示例</td>
<td>示例</td>
</tr>
<tr>
<td>示例</td>
<td>示例</td>
<td>示例</td>
</tr>
</table>
</body>
</html>效果图:

border 简写属性在一个声明设置所有的边框属性。
可以按顺序设置如下属性:
border-width:规定边框的宽度。
border-style:规定边框的样式。
border-color:规定边框的颜色。
以上就是html表格边框的详细内容,更多请关注Gxl网其它相关文章!