Open In App

HTML | <input type=”week”>

Last Updated : 02 Jun, 2022
Improve
Improve
Like Article
Like
Save
Share
Report

The HTML <input type=”week”> is used to define a week and a year control field

Syntax: 

<input type="week">

Example: 

HTML




<!DOCTYPE html>
<html>
 
<head>
    <title>
        HTML Input Type week
    </title>
</head>
<style>
    #Geek_p {
        font-size: 30px;
        color: green;
    }
</style>
 
<body style="text-align:center;">
 
    <h1 style="color:green;">
            GeeksForGeeks
        </h1>
 
    <h2>HTML &lt;Input Type="week"&gt;
</h2>
    <form>
        <input type="week">
        <br>
        <br>
 
    </form>
</body>
 
</html>


Output:

  

Supported Browsers: The browser supported by HTML Input type=”week” are listed below:

  • Google Chrome 20 and above
  • Edge 12 and above
  • Opera 11 and above
  • Internet Explorer not supported 
  • Firefox not supported 
  • Safari not supported 

Like Article
Suggest improvement
Share your thoughts in the comments

Similar Reads