-
去掉父元素的 overflow: hidden,或者设置成 overflow: visible
-
如果父元素的 overflow: hidden 不能动,动了会造成其他影响,
那么可以: 给父元素加一个足够的内边距,这样就可以让定位元素显示,但是父元素占得位置会变大,这时候再设置个负的外边距,跟内边距抵消就可以了.
.parent{
position: relative;
padding-bottom: 500px;
margin-bottom: -500px;
.child{
position: absolute;
left: 0;
top:100%;
z-index: 10;
}
}