PHP code example of rebelinblue / laravel-zxcvbn
1. Go to this page and download the library: Download rebelinblue/laravel-zxcvbn 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/ */
rebelinblue / laravel-zxcvbn example snippets
'Zxcvbn' => REBELinBLUE\Zxcvbn\ZxcvbnFacade::class,
use Zxcvbn;
class MyCustomClass
{
public function someMethod()
{
$strength = Zxcvbn::passwordStrength('Pa$$w0rd');
dd($strength);
}
}
$input = [ /* user input */ ];
$validator = Validator::make($input, [
'password' => '
'password' => '
bash
php artisan vendor:publish --provider="REBELinBLUE\Zxcvbn\ZxcvbnServiceProvider"