Input Date formProperty
Examples
Return the form id containing the <input type="date"> element:
var x = document.getElementById("myDate").form.id;
xThe output result is:myForm
Try it Yourself »
Definition and Usage
The form property returns a reference to the form that contains the date field.
This property returns a form object on success.
Note:This property is read-only.
Browser Support
![]()
![]()
![]()
![]()
![]()
All mainstream browsers support the form property.
Note:Internet Explorer or Firefox browsers do not support the <input type="date"> element.
Syntax
inputdateObject.form
Technical Details
| Return value: | A reference to the form element that contains the date field. If the date control is not inside a form, returns null. |
|---|
Input Date Object Other Extensions