Input Datetime type 属性
定义和用法
type
属性返回日期字段是哪种类型的表单元素。
注释:在下面的例子中:
- Safari 和 Opera 12(及更早版本)返回 "
datetime
" - Opera 15(及更新版本)、Internet Explorer、Firefox 和 Chrome 返回 "
text
"
语法
datetimeObject.type
Technical Details
Return Value: | String value, indicating the type of form element to which the date-time field belongs. |
---|
Browser Support
The numbers in the table indicate the first browser version that fully supports this property.
Chrome | Edge | Firefox | Safari | Opera |
---|---|---|---|---|
Chrome | Edge | Firefox | Safari | Opera |
Support | 10.0 | Support | Support | Support |
Note:The <input type="datetime"> element does not display any date-time field/calendar in any mainstream browser except Safari.