HTML5 - email



It accepts only email value. This type is used for input fields that should contain an e-mail address. If you try to submit a simple text, it forces to enter only email address in email@example.com format.

Example

<!DOCTYPE HTML>

<html>
   <body>

      <form action = "/cgi-bin/html5.cgi" method = "get">
         Enter email : <input type = "email" name = "newinput" />
         <input type = "submit" value = "submit" />
      </form>

   </body>
</html>

Output

html5_web_forms2.htm
Advertisements