上一页 1 ··· 8 9 10 11 12 13 下一页
摘要: box-sizing: border-box盒子内边距不增大 *{ /*不增大*/ box-sizing: border-box; } 设置后父元素就不会跟着增大了 阅读全文
posted @ 2022-05-10 16:38 hi123hi159 阅读(70) 评论(0) 推荐(0)
摘要: 字体垂直居中 /*文字垂直居中,50为盒子的高度*/ line-height:50px 阅读全文
posted @ 2022-05-10 16:18 hi123hi159 阅读(64) 评论(0) 推荐(0)
摘要: list-style:none去掉列表的符号: ul{ list-style:none; } 阅读全文
posted @ 2022-05-10 16:12 hi123hi159 阅读(250) 评论(0) 推荐(0)
摘要: 代码如下: a{ text-decoration: none; width: 100px; height: 50px; background-color: red; display: inline-block; color: white; text-align: center; line-heigh 阅读全文
posted @ 2022-05-10 13:18 hi123hi159 阅读(75) 评论(0) 推荐(0)
摘要: a标签转块 a{ text-decoration: none; width: 100px; height: 50px; background-color: red; display: inline-block; color: white; text-align: center; line-heigh 阅读全文
posted @ 2022-05-10 13:13 hi123hi159 阅读(72) 评论(0) 推荐(0)
摘要: display: inline-block: 将多个div转换成在同一行 代码如下: div{ /*将多个块转换成在同一行*/ display: inline-block; } 阅读全文
posted @ 2022-05-10 12:55 hi123hi159 阅读(170) 评论(0) 推荐(0)
摘要: 去除html页面和body之间的空白 代码如下: * { margin: 0; padding: 0; } 阅读全文
posted @ 2022-05-10 12:39 hi123hi159 阅读(126) 评论(0) 推荐(0)
摘要: 背景图垂直水平居中: background-position: center; 阅读全文
posted @ 2022-05-10 12:29 hi123hi159 阅读(99) 评论(0) 推荐(0)
摘要: 背景图拉伸铺满 background: url("img.jpg") no-repeat; background-size:100% 100%; 阅读全文
posted @ 2022-05-10 12:24 hi123hi159 阅读(199) 评论(0) 推荐(0)
摘要: 超链接去下划线: a{ /*超链接去下划线*/ text-decoration: none; } 阅读全文
posted @ 2022-05-10 11:56 hi123hi159 阅读(162) 评论(0) 推荐(0)
上一页 1 ··· 8 9 10 11 12 13 下一页