textarea自动适应高度,兼容IE/Firefox、chrome
代码:
<textarea name="textarea" id="textarea" style=\'overflow-y: hidden;height:20px\' onpropertychange="this.style.height = this.scrollHeight + \'px\';" oninput="this.style.height = this.scrollHeight + \'px\';">
</textarea>