Input Week typeProperty
Examples
Return the form type of the week field:
var x = document.getElementById("myWeek").type;
xThe output value is:
week
Try it Yourself »
Definition and Usage
The type property returns the form element type of the week field.
Note:In the above examples, Opera, Chrome, and Safari browsers return "week", but Internet Explorer and Firefox browsers return "text".
Browser Support
![]()
![]()
![]()
![]()
![]()
All major browsers support the type property.
Note:Internet Explorer or Firefox browsers do not support the `<input type="week">` element.
Syntax
weekObject.type
Technical Details
| Return Value: | A string, representing the form element type of the week field. |
|---|
Input Week Object Other Extensions