虽然网页布局早已经是div+css的天下了,但是有时候我们或多或少还是会用到table。
今天给大家推荐两种设置表格边框的方法
1,通过table属性设置边框
<table width="80%" height="400" border="1" cellpadding="0" cellspacing="0">
2.通过css样式设定边框(推荐使用这种方式)
<style type="text/css">
table{ border-collapse:collapse;}
td{ border:1px solid red;}
</style>