PHP code example of andrey-helldar / blacklist-server

1. Go to this page and download the library: Download andrey-helldar/blacklist-server 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/ */

    

andrey-helldar / blacklist-server example snippets


use Helldar\BlacklistServer\Facades\Blacklist;

return Blacklist::store('[email protected]', 'email') : Helldar\BlacklistServer\Models\Blacklist
return Blacklist::check('[email protected]') // throw Helldar\BlacklistCore\Exceptions\BlacklistDetectedException if exists.
return Blacklist::exists('[email protected]') : bool

return Blacklist::store('http://example.com', 'url') : Helldar\BlacklistServer\Models\Blacklist
return Blacklist::check('http://example.com') // throw Helldar\BlacklistCore\Exceptions\BlacklistDetectedException if exists.
return Blacklist::exists('http://example.com') : bool

return Blacklist::store('192.168.1.1', 'ip') : Helldar\BlacklistServer\Models\Blacklist
return Blacklist::check('192.168.1.1') // throw Helldar\BlacklistCore\Exceptions\BlacklistDetectedException if exists.
return Blacklist::exists('192.168.1.1') : bool

return Blacklist::store('+0 (000) 000-00-00', 'phone') : Helldar\BlacklistServer\Models\Blacklist
return Blacklist::check('+0 (000) 000-00-00') // throw Helldar\BlacklistCore\Exceptions\BlacklistDetectedException if exists.
return Blacklist::exists('+0 (000) 000-00-00') : bool

php artisan vendor:publish --provider="Helldar\BlacklistClient\ServiceProvider"