JavaScript document forms Property Tutorial

In this section, we will learn what the document forms property is and how to use it in JavaScript.

What is document forms Property in JavaScript?

The JavaScript document forms property is used to get a collection object that contains the entire <form> elements in an HTML document.

document forms Property Syntax:

document.forms;

document forms Property Input Value

The property is read-only.

document forms Method Return Value

The return value of this property is a collection object that contains all the <form> elements in an HTML document.

Example: using document forms Property in JavaScript

See the Pen using document forms Property in JavaScript by Omid Dehghan (@odchan1) on CodePen.

Facebook
Twitter
Pinterest
LinkedIn

Top Technologies