为什么这个边框右边会有一个缝隙,新手上路真的不知道问题出在哪里
1条回答 默认 最新
关注 表格(如果有启用border)外边框始终会存在一层border
通过背景色遮挡缝隙table { background-color: black; } tr { background-color: white; }
<!DOCTYPE html> <html lang="en"> <head> <meta charset="UTF-8" /> <meta http-equiv="X-UA-Compatible" content="IE=edge" /> <meta name="viewport" content="width=device-width, initial-scale=1.0" /> <title>Document</title> <style> table { background-color: black; } tr { background-color: white; } </style> </head> <body> <table align="center" border="1" cellpadding="10px" cellspacing="0px" width="500" height="249" > <tr> <th>及格否</th> <th>姓名</th> <th>分数</th> </tr> <tr> <th>及格</th> <th>小明</th> <th>88</th> </tr> <tr> <th>及格</th> <th>小红</th> <th>86</th> </tr> <tr> <th>不及格</th> <th>小军</th> <th>56</th> </tr> </table> </body> </html>
本回答被题主选为最佳回答 , 对您是否有帮助呢?解决 1无用
悬赏问题
- ¥20 机器学习能否像多层线性模型一样处理嵌套数据
- ¥20 西门子S7-Graph,S7-300,梯形图
- ¥50 用易语言http 访问不了网页
- ¥50 safari浏览器fetch提交数据后数据丢失问题
- ¥15 matlab不知道怎么改,求解答!!
- ¥15 永磁直线电机的电流环pi调不出来
- ¥15 用stata实现聚类的代码
- ¥15 请问paddlehub能支持移动端开发吗?在Android studio上该如何部署?
- ¥20 docker里部署springboot项目,访问不到扬声器
- ¥15 netty整合springboot之后自动重连失效