input type=month element | input type=month object

Creates a month entry control.

HTML5 A vocabulary and associated APIs for HTML and XHTML, 4.10.5.1.9

 

DOM Information

Inheritance Hierarchy

 Node
  Element
   HTMLElement
     input type=month

Members

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

Events

The input type=month object has these events.

EventDescription
oninvalid

Provides specified alert text if an input element is invalid.

 

Standards information

Remarks

Note  Returns a date-formatted string containing a numeric representation of the year and month, such as 2015-02 for February 2015.
 

Examples

This example uses the input type=month element to create an empty month control.


<input type="date" value="" name="userMonth">

See also

Node
Reference
input
validity
formNoValidate

 

 

Show: