alli lo tienes, lo saque de esta pagina
http://www.codelifter.com/main/javas...schecker1.html
y fue tan simple como buscar "javascript mail validator" en google.com, echale ganas
================================================== ==========
Script: Email Address Checker-Validator
Functions:
Checks name field to see if empty
Checks e-mail address, which must have:
- "@" symbol and no spaces
- one or more good characters before
and after "@"
- .xx country code or .com, .net,
.edu, .mil, .gov, .org at end
First (em) and second (emx) email addresses
must be equal and name field must have more
than one character to pass the script tests
Browsers: All 4.0 and later browsers
Author: etLux
================================================== ==========
Put the following form and script in the body of your page:
<font size="2" face="Arial" color="#FF0000">
<form name="TheForm">
<input type="text" name="nm" size="33"> Your Name
<br><br>
<input type="text" name="em" size="33"> E-mail address
<br>
<input type="text" name="emx" size="33"> Re-enter to confirm
<br><br>
<input type="button" value="Submit" name="SB" onClick="sendOff();">
<script language="JavaScript1.2">
// (C) 2000
www.CodeLifter.com
//
http://www.codelifter.com
// Free for all users, but leave in this header
var good;
function checkEmailAddress(field) {
// Note: The next expression must be all on one line...
// allow no spaces, linefeeds, or carriage returns!
var goodEmail = field.value.match(/\b(^(\S+@).+((\.com)|(\.net)|(\.edu)|(\.mil)|(\.go v)|(\.org)|(\..{2,2}))$)\b/gi);
if (goodEmail){
good = true
} else {
alert('Please enter a valid e-mail address.')
field.focus()
field.select()
good = false
}
}
function sendOff(){
nmcheck = document.TheForm.nm.value
if (nmcheck.length <1) {
alert('Please enter your name.')
return
}
good = false
checkEmailAddress(document.TheForm.em)
if ((document.TheForm.em.value ==
document.TheForm.emx.value)&&(good)){
// This is where you put your action
// if name and email addresses are good.
// We show an alert box, here; but you can
// use a window.location= 'http://address'
// to call a subsequent html page,
// or a Perl script, etc.
alert("Name and email address fields verified good.")
}
if ((document.TheForm.em.value !=
document.TheForm.emx.value)&&(good)){
alert('Both e-mail address entries must match.')
}
}
</script>
</form>
</font>
================================================== ==========