PHP code example of dillchuk / email-blur
1. Go to this page and download the library: Download dillchuk/email-blur 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/ */
dillchuk / email-blur example snippets
beto\EmailBlur\Blur;
$blur = new Blur();
$obscured = $blur->make('[email protected]');
var_dump($obscured); // exa***@t***.com
$blur = new Blur(mask: '<REDACTED>');
$obscured = $blur->make('[email protected]');
var_dump($obscured); // exa<REDACTED>@t<REDACTED>.com
$blur = new Blur();
$obscured = $blur->make('[email protected]');
var_dump($obscured); // exa***@gmail.com
$blur = new Blur(maskFree: true);
$obscured = $blur->make('[email protected]');
var_dump($obscured); // exa***@gm***.com
$blur = new Blur();
$obscured = $blur->make('[email protected]');
var_dump($obscured); // exa***@exa***.co.uk