Validating an email address in HTML5 by Brad Jones | JavaScriptSource

Validating an email address in HTML5 by Brad Jones

Brad Jones May 17, 2012

Abstract

Validating an email address in HTML5 is very simple.

Description

Validating an email address in HTML5 is very simple. The work is all done for you with a new control.

Code Snippet

<body>
<form action="http://www.example.org/subsribe.php">
<p>Enter an email address: </p>
<input type="email" name="email" />
<input type="submit" value="Submit" />
</form>

</body>

Leave a Response

(2 comments)

Exactly how does making the input type "email" work? This is the dumbest "code" I've ever seen on this site.

mystic7 Aug 8, 2012

this is really very useful for me :) thanx

trishna singh Jul 22, 2012