我试图让一些div环绕在一张图片周围,但是失败了。
由于在StackOverFlow中粘贴HTML似乎不起作用,所以这里是我当前尝试模仿Outlook 2010联系人条目的代码。
源自:http://www.perfmon.com/download/contactdivtest.htm (编辑:或者查看@Hristo的酷炫在线编辑器)
由于在StackOverFlow中粘贴HTML似乎不起作用,所以这里是我当前尝试模仿Outlook 2010联系人条目的代码。
源自:http://www.perfmon.com/download/contactdivtest.htm (编辑:或者查看@Hristo的酷炫在线编辑器)
<html>
<head>
<title>
</title>
<style type="text/css">
.contactLarge{
width: 250px;
height: 220px;
}
img.picture {
margin-left: 0px;
margin-bottom: 0px;
float: left;
}
.contactLarge item{
}
</style>
</head>
<body>
<div class="contactLarge">
<div style="background-color:#C5CED8;clear:both">title </div>
<img class="picture" width="100" height="200" src="ContactBigLeftBorder.png" alt="">
First, Last <br>
First, Last <br>
First, Last <br>
First, Last <br>
<div style="width:100%;font-weight:bold; float: left;">LastName, Firstname</div>
<div style="font-weight:bold;clear:both;" >CompanyName</div>
<div >Title</div>
<div >Work#</div>
<div >Mobile#</div>
<div >Home</div>
<div >email1</div>
<div >email2</div>
<div >email3</div>
<div >Street</div>
<div style="background-color:#F1F5F9; float:left;" >City,</div>
<div style="background-color:#F1F5F9; float:left;" >State</div>
<div style="background-color:#F1F5F9;" >Zip</div>
<div style="background-color:#F1F5F9; clear:left; float:left;" >httppage</div>
<div style="background-color:#F1F5F9; ">im</div>
</div>
</body>
</html>
有人能告诉我如何让所有的div向上移动并围绕着图片排列吗?我真的希望我没有错过什么简单的东西...
这是我想要实现的目标布局: