PHP code example of kevinpareek / emailchecker
1. Go to this page and download the library: Download kevinpareek/emailchecker library. Choose the download type require. 2. Extract the ZIP file and open the index.php. 3. Add this code to the index.php.
<?php
require_once('vendor/autoload.php');
/* Start to develop here. Best regards https://php-download.com/ */
kevinpareek / emailchecker example snippets
// Require Composer's autoloader.
k\EmailChecker\EmailChecker;
$emailChecker = new EmailChecker();
//check email
$isValidEmail = $emailChecker->checkEmail('[email protected]', true);
print_r($isValidEmail);
//output
// Array
// (
// [success] => 1
// [dispossable] => Array
// (
// [success] => 1
// [detail] => Email address is not disposable
// )
// [mxrecord] => Array
// (
// [success] => 1
// [detail] => MX record found but could not connect to server
// )
// [domain] => Array
// (
// [success] => 1
// [detail] => Domain is exist.
// )
// )