gpt4 book ai didi

html - 难以将元素与 Bootstrap 对齐

转载 作者:太空宇宙 更新时间:2023-11-04 15:13:33 24 4
gpt4 key购买 nike

我在处理某些 CSS/HTML 属性时遇到了一些困难。我正在使用 bootstrap 进行良好的渲染。

所以我想要这个: enter image description here

img 是完美的,但问题出在日期 (02.03.2013) 上。我在 img 上留下了一个 float ,所以 h3 可以完美地工作,但不是日期。

你能帮帮我吗?这是我所拥有的:http://jsbin.com/uqadoc/1/edit

最佳答案

<h3> 周围放置一个 div和 <p> (你的约会对象)具有固定宽度的 H3 和 Float:left;和 p, float:right;

注意:我在 jf 中进行了非 div 宣传,但概念相同

  <div class='main'>
<img src='' class='ims'>
<div class='content'>

<h3 class="qwe" >serwqerqwrewqr</h3>



<p class="wer">dafdf</p>
<div class="rty" >


sfdg
ffffffffffffffffffffff
fdsffffffffffff</br>


sfdg
ffffffffffffffffffffff
fdsffffffffffff</br> sfdg
ffffffffffffffffffffff
fdsffffffffffff</br> sfdg
ffffffffffffffffffffff
fdsffffffffffff</br>
</div>
</div>
</div>


.main{
width:500px;
height:200px;
background:black;
}
.content{
width:100ps;
height:200px;
background:red;
}
.ims{
float:left;
width:100px;
height:200px;
background:blue;
}
.qwe{
float:left;
width:300px
height:50px;
}

.wer{

width:200px
height:50px;
float:right;
}
.rty{
padding-top:80px;
width:400px
float:right;
}

fiddle http://jsfiddle.net/qAEzr/

关于html - 难以将元素与 Bootstrap 对齐,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/15176233/

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