PHP FILTER_SANITIZE_EMAIL Filter

The FILTER_SANITIZE_EMAIL filter removes all illegal characters from an email address.

Example -