for testing and deploying your application
for finding and fixing issues
for empowering human code reviews
<?php
namespace WSW\Email;
/**
* Trait Validator
*
* @package WSW\Email
* @author Ronaldo Matos Rodrigues <[email protected]>
*/
trait Validator
{
* @param string $email
* @return bool
protected function emailIsValid($email)
return (bool) filter_var($email, FILTER_VALIDATE_EMAIL);
}
* @param string $domain
protected function checkMxIsValid($domain)
return (bool) checkdnsrr($domain, 'MX');