Jesus · Bible · HTML · CSS · JS · PHP · SVG · Applications

textarea

Description

The textarea element for HTML represents a multiline plain text edit control for the element's raw value.

Syntax

HTML

<textarea attribute-name="attribute-value"></textarea>

Attributes

Global

NameValueDescription
autocompleteon | offSpecifies whether the element represents an input control for which a UA is meant to store the value entered by the user (so that the UA can prefill the form later)
autofocusautofocus | emptySpecifies that the element represents a control to which a UA is meant to give focus as soon as the document is loaded
colspositive integerExpected maximum number of characters per line of text for the UA to show
dirnamestringEnables submission of a value for the directionality of the element, and gives the name of the field that contains that value
disableddisabled | emptySpecifies that the element represents a disabled control
formIDREFIdentifies a form with which to associate the element
maxlengthpositive integerMaximum length of value
minlengthpositive integerMinimum length of value
namestringName part of the name/value pair associated with this element for the purposes of form submission
placeholderstringShort hint (one word or a short phrase) intended to aid the user when entering data into the control represented by its element
readonlyreadonly | emptySpecifies that element represents a control whose value is not meant to be edited
requiredrequired | emptySpecifies that the element is a required part of form submission
rowspositive integerNumber of lines of text for the UA to show
wraphard | softInstructs the UA to insert line breaks into the submitted value of the textarea such that each line has no more characters than the value specified by the cols attribute

Instructs the UA to add no line breaks to the submitted value of the textarea

Examples

1 · autocomplete · off

2 · autocomplete · on

3 · autofocus

4 · cols

5 · dirname

6 · disabled

7 · form

8 · maxlength

9 · minlength

10 · name

11 · placeholder

12 · readonly

13 · required

14 · rows

15 · wrap · hard

16 · wrap · soft

!doctype

a

abbr

address

area

article

aside

audio

b

base

bdi

bdo

blockquote

body

br

button

canvas

caption

cite

code

col

colgroup

data

datalist

dd

del

details

dfn

dialog

div

dl

dt

em

embed

fieldset

figcaption

figure

footer

form

h1

h2

h3

h4

h5

h6

head

header

hgroup

hr

html

i

iframe

img

input

ins

kbd

label

legend

li

link

main

map

mark

menu

meta

meter

nav

noscript

object

ol

optgroup

option

output

p

param

picture

pre

progress

q

rb

rp

rt

rtc

ruby

s

samp

script

search

section

select

slot

small

source

span

strong

style

sub

summary

sup

table

tbody

td

template

tfoot

th

thead

time

title

tr

track

u

ul

var

video

wbr

Web Hypertext Application Technology Working Group (WHATWG)

HomeMenu