Javascript validate email

The Javascript email validation function below will return true if email is correct, false – otherwise.

There is only one argument to this validation function its email address.

Source code for webtoolkit.emailvalidation.js

function validEmail(email){      
	var emailReg = /^[a-zA-Z0-9._-]+@[a-zA-Z0-9.-]+\.[a-zA-Z]{2,4}$/;
	return emailReg.test(email); 
}