让IE6支持最小高度min-height、最大高度max-height的方
建站知识 2021-07-03 08:15www.168986.cn长沙网站建设
1、IE6支持max-height解决方法
IE6支持最大高度解决CSS代码
.yangshi{max-height:1000px;_height:expression((document.documentElement.clientHeight||document.body.clientHeight)<1000?"1000px":"");overflow:hidden;}
说明max-height:1000px; 这个是IE6以上级其它品牌浏览器支持最大范围高度。而_height:expression((document.documentElement.clientHeight||document.body.clientHeight)<1000?"1000px":"");overflow:hidden;则是让IE6支持max-height替代CSS代码,但效果和其它版本浏览器相同效果。
让所有浏览器都支持max-height的CSS样式代码,完整
max-height:1000px;_height:expression((document.documentElement.clientHeight||document.body.clientHeight)<1000?"1000px":""); overflow:hidden;这里的1000和1000px是你需要的数值,注意3个数值的相同。
让IE6支持最大高度max-height的时候别忘记加上overflow:hidden;
2、IE6支持min-height解决方法
IE6支持最小高度解决CSS代码
.yangshi{min-height:1000px;_height:expression((document.documentElement.clientHeight||document.body.clientHeight)>1000?"1000px":"");}
说明min-height:1000px; 这个是IE6以上级其它品牌浏览器支持最小范围高度。而_height:expression((document.documentElement.clientHeight||document.body.clientHeight)>1000?"1000px":"");则是让IE6支持min-height替代CSS代码,但效果和其它版本浏览器相同效果。
让所有浏览器都支持min-height的CSS样式代码,完整
min-height:1000px;_height:expression((document.documentElement.clientHeight||document.body.clientHeight)>1000?"1000px":""); 这里的1000和1000px是你需要的数值,注意3个数值的相同。
3、IE6支持max-height又支持min-height方法
让所有浏览器包括IE6即支持最大高度又支持最小高度。
.yangshi{Max-Height:620px;Min-Height:40px;_height:expression(this.scrollHeight > 620 ? "620px" : (this.scrollHeight < 40 ? "40px" : "auto"));}
IE6支持Max-Height和支持Min-Height CSS代码
_height:expression(this.scrollHeight > 620 ? "620px" : (this.scrollHeight < 40 ? "40px" : "auto"));
说明以上代码作用是让对象的最小高度为40px,最大高度为620px的CSS样式属性
IE6支持最大高度解决CSS代码
复制代码
代码如下:.yangshi{max-height:1000px;_height:expression((document.documentElement.clientHeight||document.body.clientHeight)<1000?"1000px":"");overflow:hidden;}
说明max-height:1000px; 这个是IE6以上级其它品牌浏览器支持最大范围高度。而_height:expression((document.documentElement.clientHeight||document.body.clientHeight)<1000?"1000px":"");overflow:hidden;则是让IE6支持max-height替代CSS代码,但效果和其它版本浏览器相同效果。
让所有浏览器都支持max-height的CSS样式代码,完整
max-height:1000px;_height:expression((document.documentElement.clientHeight||document.body.clientHeight)<1000?"1000px":""); overflow:hidden;这里的1000和1000px是你需要的数值,注意3个数值的相同。
让IE6支持最大高度max-height的时候别忘记加上overflow:hidden;
2、IE6支持min-height解决方法
IE6支持最小高度解决CSS代码
复制代码
代码如下:.yangshi{min-height:1000px;_height:expression((document.documentElement.clientHeight||document.body.clientHeight)>1000?"1000px":"");}
说明min-height:1000px; 这个是IE6以上级其它品牌浏览器支持最小范围高度。而_height:expression((document.documentElement.clientHeight||document.body.clientHeight)>1000?"1000px":"");则是让IE6支持min-height替代CSS代码,但效果和其它版本浏览器相同效果。
让所有浏览器都支持min-height的CSS样式代码,完整
min-height:1000px;_height:expression((document.documentElement.clientHeight||document.body.clientHeight)>1000?"1000px":""); 这里的1000和1000px是你需要的数值,注意3个数值的相同。
3、IE6支持max-height又支持min-height方法
让所有浏览器包括IE6即支持最大高度又支持最小高度。
复制代码
代码如下:.yangshi{Max-Height:620px;Min-Height:40px;_height:expression(this.scrollHeight > 620 ? "620px" : (this.scrollHeight < 40 ? "40px" : "auto"));}
IE6支持Max-Height和支持Min-Height CSS代码
复制代码
代码如下:_height:expression(this.scrollHeight > 620 ? "620px" : (this.scrollHeight < 40 ? "40px" : "auto"));
说明以上代码作用是让对象的最小高度为40px,最大高度为620px的CSS样式属性
长沙网站设计
- 如何进行东阳SEO关键词优化?
- 边坝哪有关键词排名优化:提升你的网站流量与
- 安国百度优化服务:提升您的在线可见性
- 阜康新手做SEO怎么做
- 山西seo网站排名关键词优化:提升您网站曝光率
- 临沂seo网站排名关键词优化:提高你的网站可见
- 广西SEO网站推广怎样付费比较合理
- 双辽SEO网站推广:提升你的网站可见性与流量
- 辽宁企业网站优化购买方式有哪些
- 提升宝清百度SEO排名的实用技巧与策略
- 静宁百度SEO排名:提升您网站曝光率的关键策略
- 彭州百度SEO排名的提升策略和实施指南
- 广南百度关键词SEO:提升网站排名的关键策略
- 辽宁关键词优化怎么做论坛营销
- 吉林百度seo排名如何做到让用户满意
- 内黄百度优化服务:提升在线可见性的关键