Created
June 19, 2014 15:14
-
-
Save hjzheng/9d5ba5f08b8db46e6bed to your computer and use it in GitHub Desktop.
HTML中Table特性
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
th,td{padding:0;} | |
table{border-collapse:collapse;} | |
/* table css reset */ | |
th,td{border:1px solid black; height:50px; width:100px;} | |
table{width:500px;} | |
注意事项: | |
1、不要给table,th,td以外的表格标签加样式; | |
2、单元格默认平分table 的宽度 | |
3、th里面的内容默认加粗并且左右上下居中显示 | |
4、td里面的内容默认上下居中左右居左显示 | |
5、 table 决定了整个表格的宽度; | |
6、table里面的单元格宽度会被转换成百分比; | |
7、 表格里面的每一列必须有宽度; | |
8、表格同一竖列继承最大宽度; | |
9、表格同行继承最大高度; |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment