Javascript examples for DOM HTML Element:Textarea
Textarea rows Property - Change the height and width of a text area using the cols and rows properties:
<!DOCTYPE html> <html> <body> <textarea id="myTextarea"> new value//www . j ava2 s . c o m </textarea> <button type="button" onclick="myFunction()">Test</button> <script> function myFunction() { document.getElementById("myTextarea").style.height = "100px"; document.getElementById("myTextarea").style.width = "500px"; } </script> </body> </html>