HTML <textarea> cols Attributo

❮ Tag HTML <textarea>

Esempio

Un'area di testo con un'altezza e una larghezza specificate:

<textarea rows="4" cols="50">
At w3schools.com you will learn how to make a website. We offer free tutorials in all web development technologies.
</textarea>

Definizione e utilizzo

L' colsattributo specifica la larghezza visibile di un'area di testo.

Suggerimento: la dimensione di un'area di testo può essere impostata anche dalle proprietà di altezza e larghezza CSS.


Supporto browser

Attribute
cols Yes Yes Yes Yes Yes

Sintassi

<textarea cols="number">

Valori di attributo

Value Description
number Specifies the width of the text area (in average character width). Default value is 20

❮ Tag HTML <textarea>