中易网

在DIVCSS布局里面这margin:0 auto; width:990px; height:300px; overflow:hidden;} float:left; 什么意思?

答案:2  悬赏:60  
解决时间 2021-04-27 20:15
  • 提问者网友:白越
  • 2021-04-27 13:33
.content{ margin:0 auto; width:990px; height:300px; overflow:hidden;}
.contentleft{ float:left; width:700px; height:300px; overflow:hidden;}
.contentright{ float:right; width:290px; height:300px; overflow:hidden; text-align:center;}
.lleft{ float:left; width:350px; height:300px; overflow:hidden; text-align:center;}

还有怎么让DIV 在同一行里面 分三块!求大侠打下代码介绍下T。T
最佳答案
  • 二级知识专家网友:放肆的依賴
  • 2021-04-27 13:57
margin:0 auto; 是边距0;width:990px; height:300px; 是宽990高300;overflow:hidden是溢出部分隐藏;float:left; 是左侧浮动
你上面这个代码应该是contentleft contentright这样2个同行包含在content里这样的效果吧
做3个一行的话div按左中右顺序调用,左边的加float:left;属性,右边的加float:right;属性,中间的不要float,三个宽度和要略小于外框宽度
全部回答
  • 1楼网友:伤口狠精致
  • 2021-04-27 14:52
margin:0 auto:可以让div居中 width:990px,div 长度 height:300px; 高度 overflow:hidden; div中的内容超过了,就隐藏 float:left;位置是 居左. 你可以下个css手册。然后在本机测试。做例子。很简单。
我要举报
如以上回答内容为低俗、色情、不良、暴力、侵权、涉及违法等信息,可以点下面链接进行举报!
点此我要举报以上问答信息!
大家都在看
推荐信息