gpt4 book ai didi

javascript - Bootstrap Grid 以错误的方式折叠 : elements lie on top of other elements

转载 作者:太空宇宙 更新时间:2023-11-04 08:27:46 25 4
gpt4 key购买 nike

我尝试创建一个显示四个客户端的网格。它在大视口(viewport)中看起来不错,但是一旦我开始缩小窗口,事情就不会正常分解/折叠,而是彼此重叠。问题尤其出在右上角的第二个客户端框上。它似乎被 4 号框隐藏了,但我不明白为什么。

这是一个 js fiddle :

https://jsfiddle.net/c54nfk43/

这是没有 CSS 文件的同一个 jsfiddle(同样糟糕):

https://jsfiddle.net/c54nfk43/1/

<?php include('header.php') ?>

<body>
<?php include('navigation.php') ?>

<div class="container-fluid">
<div class="row">
<div class="col-sm-10 offset-sm-1" style="height:500px; margin-top:50px;">
<div class="row">
<div class="col-xs-12 col-lg-6 no-padding" style="background-color: white;">

<div class="left_box">
<div class="logo_wrapper">
<a href="http://www.test.com">
<img class="client-logo" src="img/logo.png" style="width:250px; height:auto; padding-top:15px;">
</a>
</div>
<p>First client, first client, this is for the first client.First client, first client, this is for the first client.First client, first client, this is for the first client. First client, first client, this is for the first client. First client, first client, this is for the first client.</p>
<p>First client, first client, this is for the first client.First client, first client, this is for the first client.First client, first client, this is for the first client. First client, first client, this is for the first client. First client, first client, this is for the first client.</p>
<p>First client, first client, this is for the first client.First client, first client, this is for the first client.First client, first client, this is for the first client. First client, first client, this is for the first client. First client, first client, this is for the first client.</p>
<p>First client, first client, this is for the first client.First client, first client, this is for the first client.First client, first client, this is for the first client. First client, first client, this is for the first client. First client, first client, this is for the first client.</p>
</div>
</div>

<div class="col-xs-12 col-lg-6 no-padding" style="background-color: #e7ecef;">
<div class="left_box">
<div class="logo_wrapper">
<a href="http://www.other.com">
<img class="client-logo" src="img/logo.svg" style="width:200px; height:auto;">
</a>
</div>
<p>Second client, another paragraph for the second client. This one here seems to overlap and is pushed around by the others. It's very sad. Second client, another paragraph for the second client. This one here seems to overlap and is pushed around by the others. It's very sad. Second client, another paragraph for the second client. This one here seems to overlap and is pushed around by the others. It's very sad. </p>

<p>Second client, another paragraph for the second client. This one here seems to overlap and is pushed around by the others. It's very sad. Second client, another paragraph for the second client. This one here seems to overlap and is pushed around by the others. It's very sad. Second client, another paragraph for the second client. This one here seems to overlap and is pushed around by the others. It's very sad.</p>

<p>Second client, another paragraph for the second client. This one here seems to overlap and is pushed around by the others. It's very sad. Second client, another paragraph for the second client. This one here seems to overlap and is pushed around by the others. It's very sad. Second client, another paragraph for the second client. This one here seems to overlap and.</p>
</div>
</div>
</div>

</div>
</div>

<div class="row hidden-sm-down" style="margin: 75px;">

</div>

<div class="row">
<div class="col-sm-10 offset-sm-1" style="height:500px; margin-top:50px;">


<div class="row">
<div class="col-xs-12 col-lg-6 no-padding" style="background-color: white;">

<div class="left_box">
<div class="logo_wrapper">
<a href="https://www.thirdclient.de">
<img class="client-logo" src="img/thirdlogo.jpg" style="width:250px; height:auto; padding-top:-20px;">
</a>
</div>
<p>The glorious number three is here. This is for the third client. The glorious number three is here. This is for the third client. The glorious number three is here. This is for the third client. The glorious number three is here. This is for the third client.</p>
<p>The glorious number three is here. This is for the third client. The glorious number three is here. This is for the third client. The glorious number three is here. This is for the third client. The glorious number three is here. This is for the third client.</p>
<p> The glorious number three is here. This is for the third client. The glorious number three is here. This is for the third client. The glorious number three is here. This is for the third client. The glorious number three is here. This is for the third client. The glorious number three is here. This is for the third client.</p>
<p>The glorious number three is here. This is for the third client. The glorious number three is here. This is for the third client. The glorious number three is here. This is for the third client. The glorious number three is here. This is for the third client.</p>

</div>
</div>

<div class="col-xs-12 col-lg-6 no-padding" style="background-color: #e7ecef;">
<div class="left_box">
<div class="logo_wrapper">
<a href="http://www.fourthclient.com/">
<img class="client-logo" src="img/fourthlogo.jpg" style="width:200px; height:auto;">
</a>
</div>
<p>Last but not least, one more client. Number for. How we all waited for you, Number 4. Last but not least, one more client. Number for. How we all waited for you, Number 4. Last but not least, one more client. Number for. How we all waited for you, Number 4. Last but not least, one more client. Number for. How we all waited for you, Number 4. Last but not least, one more client. Number for. How we all waited for you, Number 4. Last but not least, one more client. Number for. How we all waited for you, Number 4. </p>

<p>Last but not least, one more client. Number for. How we all waited for you, Number 4. Last but not least, one more client. Number for. How we all waited for you, Number 4. Last but not least, one more client. Number for. How we all waited for you, Number 4. Last but not least, one more client. Number for. How we all waited for you, Number 4. </p>

<p>Last but not least, one more client. Number for. How we all waited for you, Number 4. Last but not least, one more client. Number for. How we all waited for you, Number 4. Last but not least, one more client. Number for. How we all waited for you, Number 4. Last but not least, one more client. Number for. How we all waited for you, Number 4. </p>
</div>
</div>
</div>

</div>
</div>
</div>

<?php include('footer.php') ?>

最佳答案

问题是您要在 div.col-sm-10 上设置 height 属性删除它,它应该可以解决问题。

希望这对您有帮助..

关于javascript - Bootstrap Grid 以错误的方式折叠 : elements lie on top of other elements,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/45030079/

25 4 0
Copyright 2021 - 2024 cfsdn All Rights Reserved 蜀ICP备2022000587号
广告合作:1813099741@qq.com 6ren.com