Textarea form property
Example
Return the id of the form that the textarea text box belongs to:
document
.
getElementById
(
"
myTextarea
"
)
.
value
=
"
Runoob
"
;
Try it »
Definition and Usage
The form property returns a reference to the form that contains the textarea element.
If successful, this property returns a form object.
Syntax
textareaObject.form
Browser support
| property | |||||
|---|---|---|---|---|---|
| form | Yes | Yes | Yes | Yes | Yes |
Technical Details
| Return value: | Returns a reference to the form that contains the textarea element, or null if the text box is not in a form. |
|---|
The Textarea object