Input Color typeProperty
Example
Return the form element type of the color picker:
var x = document.getElementById("myColor").type;
xThe output result is:color
Try it yourself »
Definition and Usage
The type property is used to return the form element type of the color picker.
The color picker's form usually returns "color".
Browser Support
![]()
![]()
![]()
![]()
![]()
All major browsers support the type property.
Note:Internet Explorer and Safari browsers do not support the <input type="color"> element.
Syntax
colorObject.type
Technical Details
| Return Value: | A string representing the form type of the color picker. |
|---|
Input Color Object Other Extensions