html - 容器不随内容流动

标签 html css wordpress

您好,我正在使用 Wordpress,

我的容器和图像标题有一些问题。

网站:http://bit.ly/19QzWbS

无论我尝试做什么,图像标题似乎都是重叠的。

我已经试过了:

.entry-content .wp-caption {
/* border: 1px solid #E0E0E0; */
/* box-shadow: 0 1px 2px rgba(0, 0, 0, 0.09);*/
-ms-box-sizing: border-box;
-moz-box-sizing: border-box;
/* -webkit-box-sizing: border-box;*/
box-sizing: border-box;
/* margin: 5px 0 30px 0;*/
max-width: 100%;
padding: 8px;
text-align: center;
}

但我仍然认为是容器。

谢谢。

最佳答案

您好,所有问题都来自样式 float:left

float: left 之后你必须 clear:both

在这个分区

<div class="symple-box blue none " style="text-align:left; width:100%;"> 


</div>

添加这个

<div class="clear"></div>

像这样的例子

 <div class="symple-box blue none " style="text-align:left; width:100%;"> 
    your code

    <div class="clear"></div>
 </div>

这在CSS中

.clear {
    clear: Both;
    margin: 0;
    padding: 0;
    width: 0;
    height: 0;
}

关于html - 容器不随内容流动,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/19445569/

相关文章:

html - 具有两列和一个页脚的液体布局

javascript - 有没有办法通过扩展在 Chrome 上对标签进行着色/着色/突出显示?

css - 溢出 : visible not working

php - WP_Query() 在自定义类中不起作用

php - 文档类型前的空格问题

javascript - 如何将逐字源代码包含到 html 文档中

javascript button.style.backgroundColor 返回 ""直到被点击

linux - 如何通过.htaccess将Wordpress 404指向URL

javascript - 删除特定类的 div

javascript - 将 div 元素与 html 元素并排对齐