2010-12-09 46 views

回答

57

top: auto; bottom:0; - autotop

+0

虽然`顶:汽车;`不回答描述中的问题,它并没有回答这是如何禁用或重置CSS规则标题中的问题。 – Alesana 2017-04-21 00:52:58

16
top: auto; 
bottom: 0px; 
1

CSS的默认值是级联的,因此,例如,如果你把p { top: 0;)第一,之后p.bottom {top:auto; bottom: 0;),你的CSS会听后者为p.bottom

+3

是的,但`bottom:0`不会覆盖`top:0`,它只会被添加到规则中,使得元素从上到下延伸 – 2010-12-09 10:15:07

12

,如果你有拉伸的问题只是用初始重置规则

top: initial; 

bottom: initial;