Daily Archives: 2012 年 10 月 17 日

textarea自动高度调整

textarea自动高度调整 让textarea根据文本的长度自动调整它的大小。 方法一: <textarea rows=1 cols=40 style='overflow:scroll;overflow-y:hidden;;overflow-x:hidden'
onfocus="window.activeobj=this;this.clock=setInterval(function(){activeobj.style.height=activeobj.scrollHeight+'px';},200);"…