87,993
社区成员
发帖
与我相关
我的任务
分享


<!doctype html>
<html lang="en">
<head>
<meta charset="UTF-8">
<meta name="viewport" content="width=device-width, initial-scale=1.0, maximum-scale=1.0, user-scalable=0" />
<title>Document</title>
<style>
*{padding:0;margin:0;}
html{zoom:1;}
body,div,dl,dt,dd,ul,ol,li,h1,h2,h3,h4,h5,h6,pre,code,form,fieldset,legend,input,textarea,p,blockquote,th,td{margin:0;padding:0;}
body{font:14px "微软雅黑","宋体";color:#000;background:#fff;max-width:414px;margin:0 auto;}
pre,input,textarea,a,select{font:14px/1.6em "微软雅黑","宋体";color:#000;word-wrap:break-word;outline-width:inherit;}
h1,h2,h3,h4,h5,h6{font-size:100%;font-weight:normal;}
img{border:none;}
a{color:#003399;font-weight:normal;text-decoration:none;}
input,img{vertical-align:middle;}/*对齐*/
li{list-style:none;}
img{width:100%;}
.tuwen{width: 96%;margin: 0 auto;margin-top: 15px;}
.tuwen_left{float:left;margin-right: 2%;}
.tuwen_left img{width:auto;height:20px;}
.tuwen_right{line-height:20px;}
</style>
</head>
<body>
<div class="tuwen">
<div class="tuwen_left"><img id="aa" src="https://avatar.csdn.net/5/6/7/2_jslang.jpg"></div>
<div class="tuwen_right" id="cc">
<p>吾问无为谓吾问无为</p>
<p>吾问无为谓吾问无为谓吾问无为谓呜呜呜呜呜呜呜呜呜呜呜呜吾问无为谓呜呜呜呜呜呜呜呜....</p>
</div>
</div>
<script>
window.onload = window.onresize = function () {
var aa = document.getElementById("aa");
var cc = document.getElementById("cc");
aa.style.height = "20px";
while (aa.offsetHeight<cc.offsetHeight) {
aa.style.height = aa.offsetHeight+20+"px";
}
}
</script>
</body>
</html>