input type=time element | input type=time object

Creates a time entry control.This control is able to set time values (hour, minute, second).

DOM Information

Inheritance Hierarchy

 Node
  Element
   HTMLElement
     input type=time

Members

The input type=time object has these types of members:

Events

The input type=time object has these events.

EventDescription
oninvalid

Provides specified alert text if an input element is invalid.

 

Standards information

Remarks

Returns a time-formatted string containing the hour, minute, and/or seconds e.g. 23:20:50

This control does not include time zone information.

Milliseconds is not supported.

Examples

This example uses the input type=time type attribute to create an empty time control that can be set to a time between 9:00 am and 5:00 pm.


<input type="time" min="09:00" max="17:00">

See also

Node
Reference
input
validity
formNoValidate

 

 

Show: