To validate email addresses in PHP 5.2 and above:
More info here: Stack Overflow
Note: Godaddy uses PHP 5.3
if (!filter_var($email, FILTER_VALIDATE_EMAIL)) {
// invalid emailaddress
}
More info here: Stack Overflow
Note: Godaddy uses PHP 5.3