ie 下 height:auto 怎么才能css 自适应高度度

DIV+CSS 自适应高度_百度知道
DIV+CSS 自适应高度
默认高度为200PX,兼容火狐浏览器,当DIV里内容超出限定时,DIV自适应高度, 要求使用纯CSS+DIV,不需要JS,,有一DIV,
提问者采纳
auto !important,7,*假定最低高度是200px*&#47,height,min-height,200px, &#47,火狐等都能兼容, 这个设置,200px,ie6,8 ,,,height,
提问者评价
楼下的也十分正确,采纳第一个回答的吧,下次一定问你
你可以把左右的最外的DIV的margin-bottom值,设为-9999,然后再把padding-bottom的值设为:9999,这样,DIV就可以自由增大,而背景也不会被改动。
其他类似问题
按默认排序
其他2条回答
中华人民共和国&lt, width,200px},text&#47,&lt,min-height,org/1999/xhtml" target="_blank">http,min borders&quot,&lt,&lt,&gt,br &#47,&#47, 加这个最小高度就可以了&lt,&#47,solid 1px #06F}&lt,中华人民共和国中华人民共和国中华人民共和国中华人民共和国&lt,&lt,&#47,html xmlns=&quot,&lt,中华人民共和国&lt,<a href="http,&gt,org/1999/xhtml&quot,100px,div&gt,borders{ border,//www,&gt,&lt,css&quot,&lt,w3,中华人民共和国&lt, &#47,br &#47,//www,br &#47,w3,title&gt,&gt,&gt,&gt,meta http-equiv=&quot,html,head&gt,div class=&quot,br &#47,Content-Type&quot,text&#47,,&#47, content=&quot,body&gt, charset=utf-8&quot,&lt,中华人民共和国&lt,无标题文档&lt,&#47,style type=&quot,title&gt,html&gt,,min{ min-height,style&gt,body&gt,head&gt,&gt,&gt,&#47,&lt,100px,
下载知道APP
随时随地咨询
出门在外也不愁IE7、FF DIV高度不能自适应问题的解决方案 - CSS教程 - CND8学院
热门标签:
您的位置: &
IE7、FF DIV高度不能自适应问题的解决方案
  发布日期:日
解决方法小结:1、父元素也浮动 (没有指定宽度的float应当伸缩包装到浮动内容的宽度)2、clear属性3、为父层设置 {overflow: _height:1%;} 前者针对火狐IE7(overflow:auto 或hidden) 后者针对IE6(_height:1% 或he\ight:1%)* html .clear{height:1%}4、父元素设置高度宽度5、针对 火狐#d1:after{content:".";height:0;visibility:display:clear:
其他小技巧:
html也要设置100%&&&& ,对后面的div可能会有影响html,body{height:100%;margin:0;}
设置 div为绝对定位. style="width:500 height:100%! background:#003333; position:"./#/需要自动高度的地方{min-height:500height:/*IE7*/_height:500/*IE6*/display:/*firefox,opera*/}
在FF下一个自适应高度的简单做法
加上height: 100%;overflow:
自动换行的简单做法
table-layout:WORD-BREAK: break-WORD-WRAP: break-
怎样用CSS把层做成半透明?
用下面的样式表定义你的层.alpha { filter: Alpha(Opacity=50, FinishOpacity=50, Style=0, StartX=0, StartY=0, FinishX=100, FinishY=100}
解释:Opacity=开始的不透明度(100的话就不透明了)FinishOpacity=结束的不透明度(100的话就不透明了)Style=样式,从0开始,1.2.3....有均匀透明啊,放射形状透明啊...StartX=开始透明的X坐标,基本上为图片、层的左上角(0)StartY= 开始透明的Y坐标,基本上也为图片、层的左上角(0)FinishX=结束透明的X坐标,基本上也图片、层的右下(图片、层的宽度)FinishY=结束透明的Y坐标,基本上也为图片、层的右下角(图片、层的高度)
相关教程:最新教程:500 - 内部服务器错误。
500 - 内部服务器错误。
您查找的资源存在问题,因而无法显示。按 & & 方向键翻页看更爽
扫描二维码,用手机看博客
&nbsp&nbsp
& &&京ICP备号ie 下 height:auto 怎么才能自适应高度_百度知道
ie 下 height:auto 怎么才能自适应高度
div id=&quot, left,div&gt,&#47,ui-widget-content&quot, z-index,div&gt, 0px,footer&quot, height,leftside&quot, 100%,&gt, top, 2, 100%,大概比如有这么3个DIV吧 第一个是在顶部的第三个是在底部的 第二个是在中间的那么比如我顶部设置了height, hidden, text-align, width,div id=&quot, ff
&lt, hidden,缺是根据内容自适应的怎么样才能完成我这样的布局呢, 50px, 16px, top &lt, 50px, hidden,&gt,&lt, }
#footer { position, 1px solid #AAAAAA,auto,40px底部设置了height, 16px, bottom,div id=&quot, width, &lt, 36px, overflow, 37px, border, z-index, class=&quot, overflow,div&gt, absolute,&gt, right,&#47, 2, text-align,
&lt,, center, absolute,auto, bottom, width, footer &lt, absolute, 2,38px我希望中间的div进行自适应高度#header { position, }
#leftside {height, border, 0px, z-index, center, }奇怪的是在firefox中可以完全符合我的需求 在IE7中第二个div height, 180px, right, 0px, height, height, border,header&quot, overflow, 1px solid #AAAAAA, 1px solid #AAAAAA,&#47, position,
提问者采纳
中间能高度自动了,height,div&gt,,left,header&quot,left,&lt,header{width,height,div class=“layout”&gt, float, float,left,&lt,style&gt, float,auto,49px,center{width,center&quot,},height,头部&lt,底部&lt,height,div class=&quot,&#47,&#47,&gt,auto,},bottom{width,&gt,900px,900px,bottom&quot,div&gt, float,}&lt,&#47,900px,中间&lt,&lt,},div class=&quot,div&gt,div class=&quot,&gt,left,&#47,&lt,auto,style&gt,&lt,div&gt,layout{width,&#47,&lt,900px,
提问者评价
其他类似问题
按默认排序
其他1条回答
&lt, &#47, &lt,#CCC,div id=&quot,p&gt, height,}#continer { width,
&lt,html&gt,relative,&#47,右边&lt, center,&#47,div&gt,}#leftside { width,}--&gt,
&lt,middle&quot,&#47,p&gt,0 auto,
&lt, background-color,p&gt,}#rightside { width,&#47,p&gt, &lt,body&gt,
&lt,你看看吧,中间左右两个块可以随内容自适应高度。-----------------------------------代码-----------------------------------------&lt,&#47,div&gt,auto,&#47,&lt,title&gt,right,text&#47,&#47, &lt,#CCC,test&lt,
&lt,p&gt,&gt,style type=&quot,&lt, 800px, text-align,&gt,左边&lt,div id=&quot,leftside&quot,p&gt,both,p&gt, width, width,&#47,div id=&quot, background-color,auto,&#47,&gt,800px,footer&quot,p&gt, float,你试试这么写,}#footer { position,p&gt,title&gt,head&gt,
&lt,p&gt,continer&quot, 50px,!--* { padding,style&gt,&#47,-------------------------------------------代码---------------------------------------------, clear, float,
&lt,顶部&lt,&#47, &lt, &lt,0px,
&lt,p&gt,&#47,relative,在firefox和IE中都可以,&lt,&#47,css&quot, margin,&#47,left,#30F,&gt,&lt,
&lt,&lt,&#47,&lt,
&lt,&#47,&lt, background-color,&lt,div id=&quot, &lt, margin,header&quot,}#middle { position,
&lt,p&gt, 36px,
&lt,div&gt, height,180px,div&gt, width,固定宽度且居中 }#header { position,p&gt,div id=&quot,
&lt, text-align, &lt,p&gt, &lt, text-align, center,&gt,p&gt,div&gt,&#47,div&gt,p&gt,p&gt,body&gt, height, height,620px,head&gt, center,p&gt, 800px,&#47,&#47,&#47, 800px,html&gt,
&lt,p&gt, background-color,&lt,rightside&quot,&gt,
&lt,div id=&quot,0px,&gt,relative,底部&lt,&#47,不知道这个是不是你想要的效果,p&gt,#0F0,&#47,
自适应的相关知识
等待您来回答
下载知道APP
随时随地咨询
出门在外也不愁

我要回帖

更多关于 css 自适应高度 的文章

 

随机推荐