PHP code example of mailboxvalidator / mailboxvalidator-cakephp

1. Go to this page and download the library: Download mailboxvalidator/mailboxvalidator-cakephp 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/ */

    

mailboxvalidator / mailboxvalidator-cakephp example snippets


Configure::write('MBV_API_KEY','PASTE_YOUR_API_KEY_HERE');

use MailboxValidatorCakePHP\Controller\MailboxValidatorController;

$MBV = new MailboxValidatorController();

->setProvider('mbv', $MBV)

->add('email', 'disposable', [
        'rule' => 'disposable',
        'provider' => 'mbv',
        'message' => 'Invalid email address. Please enter a non-disposable email address.',
])