PHP Class EmailValidator\Validator

Afficher le fichier Open project: nojacko/email-validator

Méthodes publiques

Méthode Description
hasMx ( string $email ) : boolean | null Test email address for MX records
isDisposable ( string $email ) : boolean | null Detected disposable email domains
isEmail ( string $email ) : boolean Valid email Due complexity of email validation (non-latin chars, ", .
isExample ( string $email ) : boolean | null Detected example email addresses.
isRole ( string $email ) : boolean | null Detected role based email addresses
isSendable ( string $email ) : boolean Validate an email address using isEmail, isExample and hasMx.
isValid ( string $email ) : boolean Validate an email address using ALL the functions of this library.

Private Methods

Méthode Description
hostnameFromEmail ( string $email ) : string | null Get the hostname form an email address
userFromEmail ( string $email ) : string | null Get the user form an email address

Method Details

hasMx() public méthode

Test email address for MX records
public hasMx ( string $email ) : boolean | null
$email string Address
Résultat boolean | null

isDisposable() public méthode

Detected disposable email domains
public isDisposable ( string $email ) : boolean | null
$email string Address
Résultat boolean | null

isEmail() public méthode

..), this is VERY simple. Rule: [email protected] Note: webmaster@localhost won't be valid
public isEmail ( string $email ) : boolean
$email string Address
Résultat boolean

isExample() public méthode

As defined in http://tools.ietf.org/html/rfc2606
public isExample ( string $email ) : boolean | null
$email string Address
Résultat boolean | null

isRole() public méthode

Detected role based email addresses
public isRole ( string $email ) : boolean | null
$email string Address
Résultat boolean | null

isSendable() public méthode

Validate an email address using isEmail, isExample and hasMx.
public isSendable ( string $email ) : boolean
$email string Address
Résultat boolean

isValid() public méthode

Validate an email address using ALL the functions of this library.
public isValid ( string $email ) : boolean
$email string Address
Résultat boolean