PHP code example of codes50 / password-generator
1. Go to this page and download the library: Download codes50/password-generator 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/ */
codes50 / password-generator example snippets
php
use Codes50\PasswordGenerator;
$password_generator = new PasswordGenerator();
echo $password_generator::Basic();
echo "\n";
echo $password_generator::Medium();
echo "\n";
echo $password_generator::Complex();
echo "\n";
echo $password_generator::Create(PasswordGenerator::MODE_BASIC);
echo "\n";
echo $password_generator::Create(PasswordGenerator::MODE_MEDIUM);
echo "\n";
echo $password_generator::Create(PasswordGenerator::MODE_COMPLEX);
echo "\n";
echo $password_generator::Medium(10);
echo "\n";
echo $password_generator::Complex(20);