textarea高度自适应

var tx=document.getElementById("tx");
tx.style.height=tx.scrollHeight+"px"
tx.style.backgroundColor="#89bde5"
tx.style.border="none"
tx.style.textDecoration="underline"

 

posted @ 2015-07-16 13:33  wiming  阅读(93)  评论(0编辑  收藏  举报