This question has already been answered:

There is a textarea and the value attribute contains text. How to tell textarea to stretch this tag in width?

Reported as a duplicate by members of Sasha Omelchenko , kizoso , ߊߚߤߘ , cheops , gil9red on Oct 27 '17 at 7:10 .

A similar question was asked earlier and an answer has already been received. If the answers provided are not exhaustive, please ask a new question .

1 answer 1

According to the W3 documentation, the textarea tag does not have a value attribute. To stretch the contents of this tag along the length of the browser, you can use the following options:

  • rows attribute - check the change of this attribute values ​​on the W3 Tryit Editor tool ;
  • set the styles width in% for this attribute, for example:

<!DOCTYPE html> <html> <style>textarea{width:100%}</style> <body> <textarea> At w3schools.com you will learn how to make a website. We offer free tutorials in all web development technologies. </textarea> </body> </html>