An e-mail validation class written by PHP
This article mainly introduces the use of an e-mail verification class written by PHP, very simple and practical, the need for a small partner reference, you can take it directly.
This class can be used to check whether an e-mail message is effectively using the SMTP protocol.
It can be connected to an SMTP server defined in an MX record that is verified by the domain name of the address.
And the delivery of the simulated message to see if the given recipient address is accepted as valid.
?
1 2 3 4 5 6 7 8 9 11 + + /+ //+ / + + + |
Sample !--? php //www.codepearl.com include_once ' class.verifyEmail.php '; $email = ' verify@codepearl.com '; $vmail = new Verifyemail (); If ($vmail->check ($email)) { echo ' email < '. $email. ' > exist! '; } elseif ($vmail->isvalid ($email)) { echo ' email < '. $email. ' > valid, but not exist! '; } else { echo ' email < '. $email. ' > not valid and not exist! '; } ? |
The above is the article to share all the content, I hope that you can master PHP to be helpful.
http://www.bkjia.com/PHPjc/973925.html www.bkjia.com true http://www.bkjia.com/PHPjc/973925.html techarticle PHP written an e-mail verification class This article mainly introduces the PHP written by an e-mail authentication class usage, very simple and practical, the need for a small partner reference, you can directly take away the use ...