61,115
社区成员
发帖
与我相关
我的任务
分享
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<html xmlns="http://www.w3.org/1999/xhtml">
<head>
<title></title>
<meta http-equiv="Content-Type" content="text/html;charset=utf-8">
<style type="text/css">
*{padding:0;margin:0;}
.con{width:1000px;margin:0 auto;border:1px solid #ccc;padding:10px 0;}
.con:after{clear:both;display:block;width:0;height:0;content:""}
.pic{width:200px;height:200px;float:left;border:1px solid #ccc}
.pic img{width:100px;height:80px;}
.cent{float:left;width:700px;margin-left:90px;}
</style>
</head>
<body>
<div class="con">
<div class="pic"><img src="http://t2.baidu.com/it/u=2954215716,2529633670&fm=24&gp=0.jpg" alt="猫"></div>
<div class="cent"><p>文本文本</p><p>文本文本</p><p>文本文本</p><p>文本文本</p><p>文本文本</p><p>文本文本</p><p>文本文本</p><p>文本文本</p><p>文本文本</p><p>文本文本</p><p>文本文本</p><p>文本文本</p><p>文本文本</p><p>文本文本</p><p>文本文本</p></div>
</div>
</body>
</html>
设置两个div比较靠谱一点,请忽略我简化的厉害。