Skip to content

Validate and suggest email addresses for your inputs in PHP

License

Notifications You must be signed in to change notification settings

devnix/mailcheck

Repository files navigation

Mailcheck for PHP

Validate and suggest emails for your email inputs

Disclaimer

This library uses by default a public data source to suggest various know email providers.

As this list is pretty much a work in progress you may be missing some domains, so please feel free to open an issue or a pull request to improve it.

Installation

composer require devnix/mailcheck

Usage

You just need to initialize an instance to get a shiny suggestion service!

use Devnix\Mailcheck\Mailcheck;

$mailcheck = new Mailcheck();

Then you can ask for an array of suggestions, ordered by Levenshtein distance...

$mailcheck->suggest('[email protected]');

...or just the first coincidence

$mailcheck->suggestOne('[email protected]');

Contributing

You can help by reporting bugs, submitting pull requests, providing feedback about your needs or bad suggestions.

You can execute all the tests by rugging composer test. We use tools like PHPStan, PHPUnit, and PHP CS Fixer. We like to follow the Symfony Coding Standards.

About

Validate and suggest email addresses for your inputs in PHP

Resources

License

Stars

Watchers

Forks

Packages

No packages published

Languages