1.IE6支持最大高度:
.box{_height:expression((document.documentElement.clientHeight||document.body.clientHeight)>100?"100px":"");}2、IE6支持最小高度:
.box{_height:expression((document.documentElement.clientHeight||document.body.clientHeight)<100?"100px":"");}3、同时支持,限制最大、最小高度
比如最大为620px,最小为1px
.box{_height:expression(this.scrollHeight > 620 ? "620px" : (this.scrollHeight < 1? "1px" : "auto"));}
本文详细解析了如何在IE6浏览器下通过JavaScript动态设置元素的高度,实现响应式设计,包括最大高度和最小高度的设定。
1万+

被折叠的 条评论
为什么被折叠?



