gpt4 book ai didi

html - margin 底部 :100px not working

转载 作者:太空宇宙 更新时间:2023-11-04 09:39:54 26 4
gpt4 key购买 nike

我试图在我的样式标签中使用 css .up 将图像的右侧右移到 div 标签的底部,但我发现运气不好,无法获得 iamge。任何帮助我如何获得右侧图像底部使用边距

<!DOCTYPE html>
<html lang="en">

<head>
<title>Bootstrap Case</title>
<meta charset="utf-8">
<meta name="viewport" content="width=device-width, initial-scale=1">
<link rel="stylesheet" href="https://maxcdn.bootstrapcdn.com/bootstrap/3.3.7/css/bootstrap.min.css">
<script src="https://ajax.googleapis.com/ajax/libs/jquery/1.12.4/jquery.min.js"></script>
<script src="https://maxcdn.bootstrapcdn.com/bootstrap/3.3.7/js/bootstrap.min.js"></script>
<style>
div.round1 {
border: 1px solid deepskyblue;
border-radius: 4px;
height: 170px;
width: 30%;
margin: auto;
}
.up {
margin-bottom: 350;
}
</style>
</head>

<body>

<div class="round1">

<table>
<tr>
<td>
<img src="https://placeholdit.imgix.net/~text?txtsize=12&txt=128%C3%97128&w=128&h=128" alt="Mountain1" style="width:128px;height:128px;">
<br>If a browser cannot find an image, it will display the alternate text
</td>

<td>
<img class="up" src="https://placeholdit.imgix.net/~text?txtsize=15&txt=138%C3%9770&w=138&h=70" style="width:138px;height:70px;">
</td>
</tr>

</table>
</div>

<br>
<div align="left">
<div class="container">
<ul class="nav nav-tabs">
<li class="active"><a data-toggle="tab" href="#home">One</a>
</li>
<li><a data-toggle="tab" href="#menu1">Two</a>
</li>
<li><a data-toggle="tab" href="#menu1">Functional</a>
</li>
<li><a data-toggle="tab" href="#menu3">Three</a>
</li>
</ul>

<div class="tab-content">
<div id="home" class="tab-pane fade in active">
<h3>One</h3>
<p>If a browser cannot find an image, it will display the alternate textIf a browser cannot find an image, it will display the alternate text.</p>
</div>
<div id="menu1" class="tab-pane fade">
<h3>Two</h3>
<p>If a browser cannot find an image, it will display the alternate textIf a browser cannot find an image, it will display the alternate text</p>
</div>
<div id="menu2" class="tab-pane fade">
<h3>Three</h3>
<p>If a browser cannot find an image, it will display the alternate textIf a browser cannot find an image, it will display the alternate text</p>
</div>
<div id="menu3" class="tab-pane fade">
<h3>Others</h3>
<p>If a browser cannot find an image, it will display the alternate textIf a browser cannot find an image, it will display the alternate text</p>
</div>
</div>
</div>
</div>
</body>

</html>

最佳答案

你忘记使用 px将您的代码更改为:

.up {
margin-bottom:350**px**;
}

关于html - margin 底部 :100px not working,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/40021534/

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