Skip to content

Commit

Permalink
Merge pull request #11 from aman00323/feature/update_helper
Browse files Browse the repository at this point in the history
Changes in helper file
  • Loading branch information
aman00323 authored Dec 9, 2019
2 parents b88fb18 + 4f20206 commit 4b9854e
Show file tree
Hide file tree
Showing 3 changed files with 53 additions and 34 deletions.
4 changes: 4 additions & 0 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
@@ -1,5 +1,9 @@
# CHANGELOG

## 2.1.0
- Update some character list inside helper.
- New domains added to disposable domain list, Now we have 25K domains list.

## 2.0.0
- Helper added to enhance checking of dispossable emails.
- Added deep check option in checkDisposableEmail() method.
Expand Down
7 changes: 5 additions & 2 deletions README.md
Original file line number Diff line number Diff line change
@@ -1,10 +1,13 @@
# Email Checker [![MadeWithLaravel.com shield](https://madewithlaravel.com/storage/repo-shields/1689-shield.svg)](https://madewithlaravel.com/p/email-checker/shield-link)
# Email Checker

[![MadeWithLaravel.com shield](https://madewithlaravel.com/storage/repo-shields/1689-shield.svg)](https://madewithlaravel.com/p/email-checker/shield-link) [![Maintenance](https://img.shields.io/badge/Maintained%3F-yes-green.svg)](https://GitHub.com/aman00323/StrapDown.js/graphs/commit-activity) [![GitHub license](https://img.shields.io/github/license/aman00323/email-checker)](https://github.com/aman00323/email-checker/blob/master/LICENSE) [![GitHub release](https://img.shields.io/github/v/tag/aman00323/email-checker)](https://github.com/aman00323/email-checker/releases)


Email Checker was created and maintained by [Aman Nurani](https://github.com/aman00323). It provides a powerful email validating system for both development and production for Laravel. It uses [fsockopen()](https://www.php.net/manual/en/function.fsockopen.php), [cURL](https://www.php.net/manual/en/book.curl.php) and many more to validate email address exists or not in real world.

Nowadays most of websites are using registration process where they need to verify user's ownership. Mostly developers verify email by sending email verification link to the email, So this will store extra email in database (if they were not exists in real). Additionally some people use [disposable emails](https://en.wikipedia.org/wiki/Disposable_email_address) for temporary usage.

# :tada: WE HAVE MORE THAN 25K DIPOSABLE DOMAIN LIST :tada:
<center> THIS PACKAGE WILL HELP YOU TO VERIFY EMAIL </center>

## Installation
Expand Down Expand Up @@ -74,7 +77,7 @@ app(EmailChecker::class)->checkEmail('[email protected]','boolean'));

As we have added new option with checkDisposableEmail() which has second argument that will enable deep check to compare domain with large list.

Don't worry it would't take too much time. :)
Don't worry it would't take too much time. :smile:

All are different method you can use individually as per your requirement. To call all of the method at once use **Check Email**

Expand Down
76 changes: 44 additions & 32 deletions src/Helpers/Helper.php
Original file line number Diff line number Diff line change
Expand Up @@ -9,100 +9,112 @@ public static function deepCheck(String $domain)
$startingCharacter = strtolower(substr($domain, 0, 1));
switch ($startingCharacter) {
case '0':
$url = "https://gist.githubusercontent.com/aman00323/7550b32d9334313f83fa249b8c72eb42/raw/d6c34c69facfd4a746a60839977af5a595744508/0.json";
$url = "https://gist.githubusercontent.com/aman00323/7550b32d9334313f83fa249b8c72eb42/raw";
break;
case '1':
$url = "https://gist.githubusercontent.com/aman00323/a1d5528be50a326c363d6124a8e5644a/raw/5bc33a72d2a96d5f0342527cef4be2425f608bf7/1.json";
$url = "https://gist.githubusercontent.com/aman00323/a1d5528be50a326c363d6124a8e5644a/raw";
break;
case '2':
$url = "https://gist.githubusercontent.com/aman00323/e86377dd8a9cf242c21bb04708997564/raw/2693b5d91b18b7299deef825d976e873b8b6fd0b/2.json";
$url = "https://gist.githubusercontent.com/aman00323/e86377dd8a9cf242c21bb04708997564/raw";
break;
case '3':
$url = "https://gist.githubusercontent.com/aman00323/cc0efa32545d22b24d64e7c2d869f192/raw/e697bced78526477e3407e323200f70e5b14b85c/3.json";
$url = "https://gist.githubusercontent.com/aman00323/cc0efa32545d22b24d64e7c2d869f192/raw";
break;
case '4':
$url = "https://gist.githubusercontent.com/aman00323/24f90c36d8a4a45bf9da5b3fc0dd10c9/raw/5abf47393585b98a6b688fc2189bc1800ae1c26b/4.json";
$url = "https://gist.githubusercontent.com/aman00323/24f90c36d8a4a45bf9da5b3fc0dd10c9/raw";
break;
case '5':
$url = "https://gist.githubusercontent.com/aman00323/06d9c0e0c9f47a33badb1bd69ff3dc77/raw";
break;
case '6':
$url = "https://gist.githubusercontent.com/aman00323/bd5657024f1e378ee92d9ce39074d474/raw";
break;
case '7':
$url = "https://gist.githubusercontent.com/aman00323/9937bdfba667040c4c68da473419982c/raw";
break;
case '8':
$url = "https://gist.githubusercontent.com/aman00323/b3214e77a96fb0a2097612f6197efb2e/raw";
break;
case '9':
$url = "https://gist.githubusercontent.com/aman00323/4616904635e4a2c27b80938cc2df63f0/raw/86aca2961cd102b94bb6f604665a066a83768823/9.json";
$url = "https://gist.githubusercontent.com/aman00323/4616904635e4a2c27b80938cc2df63f0/raw";
break;
case 'a':
$url = "https://gist.githubusercontent.com/aman00323/cabaa64263022478c7c68d42d746e2b5/raw/b9508986160ccb2417339955a36927549a3acc82/a.json";
$url = "https://gist.githubusercontent.com/aman00323/cabaa64263022478c7c68d42d746e2b5/raw";
break;
case 'b':
$url = "https://gist.githubusercontent.com/aman00323/43333bac0b8f74639d16817fe5135ca9/raw/5abd474e76094389a8ec98aac667bd76311751d4/b.json";
$url = "https://gist.githubusercontent.com/aman00323/43333bac0b8f74639d16817fe5135ca9/raw";
break;
case 'c':
$url = "https://gist.githubusercontent.com/aman00323/f4ccfa5b3ad08d6085fca8744737147d/raw/dd451a873a2c238586048f6330c63dc22f264a08/c.json";
$url = "https://gist.githubusercontent.com/aman00323/f4ccfa5b3ad08d6085fca8744737147d/raw";
break;
case 'd':
$url = "https://gist.githubusercontent.com/aman00323/94abf4c0575f55223ff3f9bd57f64da5/raw/25cffcfdcebd5a26113943268fe15dcd79445347/d.json";
$url = "https://gist.githubusercontent.com/aman00323/94abf4c0575f55223ff3f9bd57f64da5/raw";
break;
case 'e':
$url = "https://gist.githubusercontent.com/aman00323/b41f61d07c8ee91606a3bc7d0a666af1/raw/7ae40e1507827e61061185c6c0ff5ab7c400a824/e.json";
$url = "https://gist.githubusercontent.com/aman00323/b41f61d07c8ee91606a3bc7d0a666af1/raw";
break;
case 'f':
$url = "https://gist.githubusercontent.com/aman00323/ee4d2036450489fb884a2f628f002509/raw/8912481d022aae5426ab579f7cfe6f2cc6ea0f6b/f.json";
$url = "https://gist.githubusercontent.com/aman00323/ee4d2036450489fb884a2f628f002509/raw";
break;
case 'g':
$url = "https://gist.githubusercontent.com/aman00323/30e766e164b91a31896d98d686aa7881/raw/6bc196476a3bc30b9be6b344877438cdec1f949f/g.json";
$url = "https://gist.githubusercontent.com/aman00323/30e766e164b91a31896d98d686aa7881/raw";
break;
case 'h':
$url = "https://gist.githubusercontent.com/aman00323/b170821a66bdd59ecf2083b45a6e25eb/raw/e02e7aec9bcbe2365b016e8199fb4a976edf2eea/h.json";
$url = "https://gist.githubusercontent.com/aman00323/b170821a66bdd59ecf2083b45a6e25eb/raw";
break;
case 'i':
$url = "https://gist.githubusercontent.com/aman00323/aa4a84e3ef24d6e81b0200650e799bec/raw/e952769a03192500dbbe961502cb9922f298c336/i.json";
$url = "https://gist.githubusercontent.com/aman00323/aa4a84e3ef24d6e81b0200650e799bec/raw";
break;
case 'j':
$url = "https://gist.githubusercontent.com/aman00323/f99539b5259668222593bc1f7a0b7bc5/raw/a26598657e53729a0e1ea63b5472521401748c8d/j.json";
$url = "https://gist.githubusercontent.com/aman00323/f99539b5259668222593bc1f7a0b7bc5/raw";
break;
case 'k':
$url = "https://gist.githubusercontent.com/aman00323/061f74f1d745e6b7b53b9ce887e74bda/raw/82c4707a7566895bbfdca9e1a66bfe84fb3ebd41/k.json";
$url = "https://gist.githubusercontent.com/aman00323/061f74f1d745e6b7b53b9ce887e74bda/raw";
break;
case 'l':
$url = "https://gist.githubusercontent.com/aman00323/81ee01fcecacf40621255e3e944fd466/raw/5e1a051535c487edea0d8bac317dc2daf34ba6c2/l.json";
$url = "https://gist.githubusercontent.com/aman00323/81ee01fcecacf40621255e3e944fd466/raw";
break;
case 'm':
$url = "https://gist.githubusercontent.com/aman00323/3569bd5fc1fe62eafa9070478afd6612/raw/ef7300d388ed60ec6cc63c854a60e5e57046ff49/m.json";
$url = "https://gist.githubusercontent.com/aman00323/3569bd5fc1fe62eafa9070478afd6612/raw";
break;
case 'n':
$url = "https://gist.githubusercontent.com/aman00323/d7195298f1b3a43de9add4c02a6ef81e/raw/41a4d8d949b22e279ce1a6225ff7ebcc28d22ca6/n.json";
$url = "https://gist.githubusercontent.com/aman00323/d7195298f1b3a43de9add4c02a6ef81e/raw";
break;
case 'o':
$url = "https://gist.githubusercontent.com/aman00323/231dee6631bb9c918b25f459a2807524/raw/47fa82693853f1b068a4072c52d495d196ba1418/o.json";
$url = "https://gist.githubusercontent.com/aman00323/231dee6631bb9c918b25f459a2807524/raw";
break;
case 'p':
$url = "https://gist.githubusercontent.com/aman00323/6efecb5dc310744fa68920412eaed704/raw/f82b80e4538d76fc90a413c4fdbad2766fcc3c36/p.json";
$url = "https://gist.githubusercontent.com/aman00323/6efecb5dc310744fa68920412eaed704/raw";
break;
case 'q':
$url = "https://gist.githubusercontent.com/aman00323/2059b7492b8680991f7a010dc9dc5d1f/raw/e06414c193fab55aeabb9b397f79d670e75444d9/q.json";
$url = "https://gist.githubusercontent.com/aman00323/2059b7492b8680991f7a010dc9dc5d1f/raw";
break;
case 'r':
$url = "https://gist.githubusercontent.com/aman00323/8af0d42bd7f7a28f9bce31226005eada/raw/8bbc0b1475ef1eccff67720f431a339f11193df0/r.json";
$url = "https://gist.githubusercontent.com/aman00323/8af0d42bd7f7a28f9bce31226005eada/raw";
break;
case 's':
$url = "https://gist.githubusercontent.com/aman00323/a53320b73698cb9f0fd950584ad1306c/raw/80afa84b8ac6561a3717717554e386a8ab5f0975/s.json";
$url = "https://gist.githubusercontent.com/aman00323/a53320b73698cb9f0fd950584ad1306c/raw";
break;
case 't':
$url = "https://gist.githubusercontent.com/aman00323/5dc41bbbebbd7775e6c6a4304debf160/raw/87d281b8c33ce5c5eee8918933e8adf1e52abd43/t.json";
$url = "https://gist.githubusercontent.com/aman00323/5dc41bbbebbd7775e6c6a4304debf160/raw";
break;
case 'u':
$url = "https://gist.githubusercontent.com/aman00323/4a58e775d8841037cc2420055b69df7a/raw/af84ed99dccab7fb4f7cb7ec9a5bae23f7096ee0/u.json";
$url = "https://gist.githubusercontent.com/aman00323/4a58e775d8841037cc2420055b69df7a/raw";
break;
case 'v':
$url = "https://gist.githubusercontent.com/aman00323/e019b8059addce2d3f5ef19fc14abdb1/raw/d1d7c32c9c7ff30d1339dc6e9ea79d7ef4f2aebc/v.json";
$url = "https://gist.githubusercontent.com/aman00323/e019b8059addce2d3f5ef19fc14abdb1/raw";
break;
case 'w':
$url = "https://gist.githubusercontent.com/aman00323/4947d64ba553d3251275ab74ce3aa607/raw/96dd2f4adfa82e4eae84692ffb196cdd10948e44/w.json";
$url = "https://gist.githubusercontent.com/aman00323/4947d64ba553d3251275ab74ce3aa607/raw";
break;
case 'x':
$url = "https://gist.githubusercontent.com/aman00323/33bdf608e139be2abfaacfc63d88460f/raw/043571a7849c4ae5872d26b9328b88d213a03ba9/x.json";
$url = "https://gist.githubusercontent.com/aman00323/33bdf608e139be2abfaacfc63d88460f/raw";
break;
case 'y':
$url = "https://gist.githubusercontent.com/aman00323/77ad143b07e73e7f6b7f3baf8c79d305/raw/c84d6145105bc4b3c50c9e65bf36401c508380b9/y.json";
$url = "https://gist.githubusercontent.com/aman00323/77ad143b07e73e7f6b7f3baf8c79d305/raw";
break;
case 'z':
$url = "https://gist.githubusercontent.com/aman00323/6c02172e91fe1365d76cdf10ba8248c0/raw/1d3cb8c05a0dae9eaec332d70ba5ebf9c769345c/z.json";
$url = "https://gist.githubusercontent.com/aman00323/6c02172e91fe1365d76cdf10ba8248c0/raw";
break;
default:
return false;
Expand Down

0 comments on commit 4b9854e

Please sign in to comment.