![](https://img-blog.csdnimg.cn/20201014180756724.png?x-oss-process=image/resize,m_fixed,h_64,w_64)
css
Cziker
这个作者很懒,什么都没留下…
展开
-
Css中 单位px和em,rem的区别
PXpx像素(piexl)。相对长度单位。像素px是相对于显示器屏幕分辨率而言的。PX特点IE无法调整那些使用px作为单位的字体大小; 国外的大部分网站能够调整的原因在于其使用了em或rem作为字体单位;Firefox能够调整px和em,rem,但是96%以上的中国网民使用IE浏览器(或内核)。EMem是相对长度单位。相对于当前对象内文本的字体尺寸。如当前对行内文本...转载 2018-08-21 14:45:01 · 155 阅读 · 0 评论 -
css之position
html中的三种布局方式标准流 (网页中默认的布局方式即顺序布局) 浮动 定位HTML分为两大元素 块级元素:独占一行(div、 H1~H6、 table 表格 有序表无序表 、 p等 ) 内联元素:横水平排行(a img span input) position的定位属性(定位position来改变标准流) position属性的意义 ...原创 2018-08-21 17:26:54 · 154 阅读 · 0 评论 -
自适应网页里,字体大小自适应屏幕
字体大小使用 em, rem 作为单位,然后使用 media query 来调整 html 元素的 font-size自适应网站html {font-size: 62.5%!important; /* 10÷16=62.5% */}@media only screen and (min-width: 481px){ html { font-size: 94%!impo...转载 2018-10-27 20:54:23 · 2463 阅读 · 0 评论 -
chrome input 的背景黄色问题解决
我们登录网站并且浏览器记住密码的时候,在 chrome 中 input 会带上黄色背景解决方法input:-webkit-autofill { -webkit-box-shadow: 0 0 0px 1000px rgba(255, 255, 255, 0.5) inset !important;}...转载 2018-11-01 10:36:20 · 388 阅读 · 0 评论 -
html文字超过部分显示为省略号
一:单行文本超出 省略overflow: hidden;text-overflow: ellipsis;white-space: nowrap; //文本不换行,这样超出一行的部分被截取,显示...二、多行文本溢出overflow : hidden;text-overflow: ellipsis;display: -webkit-box; //必须结合的属性 ,将对象作为弹性伸缩盒...原创 2018-11-07 19:39:59 · 4653 阅读 · 0 评论 -
css背景滑动门
滑动门含义:自适应输入内容 <style> a { margin: 100px; height: 33px; display: inline-block; background: url(images/to.png) no-repeat; color: #fff; text-decoration: none; line-height: 33px; ...转载 2018-11-07 20:12:12 · 227 阅读 · 0 评论