Javatpoint Logo
Javatpoint Logo

HTML Date

The date is the value of the type attribute of an <input> element. It creates a calendar that allows a user to choose the date. The resulting value includes the day, month, and year.

Syntax

Example 1: The following example describes how to use the date in <input> tag:

Test it Now

Output:

HTML Date

Example 2: The following example uses the JavaScript code for displaying the date which is entered in form.

Test it Now

Output:

HTML Date

Browser Support

Elementchrome browser Chromeie browser IEfirefox browser Firefoxopera browser Operasafari browser Safari
<type="Date">YesYesYesYesYes

Next TopicHTML Form Action




Help Others, Please Share

facebook twitter pinterest

Learn Latest Tutorials


Preparation


Trending Technologies


B.Tech / MCA