PHP code example of nguyenanhung / strong-passwords-generator

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

    

nguyenanhung / strong-passwords-generator example snippets


 
uyenanhung\Library\Password\StrongPassword;



nguyenanhung\Library\Password\StrongPassword;

echo StrongPassword::generateStrongPassword('20'); // Printer: vu6QsYz@466V?FxRv*Z4
echo "\n";
echo StrongPassword::generateStrongPassword('20', TRUE); // Printer: msd!-EVbh-gd#y-v*v8-Xwdx
echo "\n";
echo StrongPassword::generateStrongPassword('20', TRUE, 'h'); // Printer: ksrg-yshs-ffdy-hyqa-heyy
echo "\n";
echo StrongPassword::generateStrongPassword('20', TRUE, 'u'); // Printer: DESS-WEHY-JPNF-HBPJ-HCYN
echo "\n";
echo StrongPassword::generateStrongPassword('20', TRUE, 'n'); // Printer: 3939-6257-5463-7739-8658
echo "\n";
echo StrongPassword::generateStrongPassword('20', TRUE, 'g'); // Printer: %@#?-?$??-*%@&-?@%#-!%!@
echo "\n";
echo StrongPassword::validStrongPassword('vu6QsYz@466V?FxRv*Z4'); // Printer: true
echo "\n";
echo StrongPassword::generateRandomPassword(36); // Printer: 3m8GRR-E!bqFz-j%P8dW-sC*h2Q-9fnY88-3Dg%8%



 generateStrongPassword('20'); // Printer: vu6QsYz@466V?FxRv*Z4
echo "\n";
echo generateStrongPassword('20', TRUE); // Printer: msd!-EVbh-gd#y-v*v8-Xwdx
echo "\n";
echo generateStrongPassword('20', TRUE, 'h'); // Printer: ksrg-yshs-ffdy-hyqa-heyy
echo "\n";
echo generateStrongPassword('20', TRUE, 'u'); // Printer: DESS-WEHY-JPNF-HBPJ-HCYN
echo "\n";
echo generateStrongPassword('20', TRUE, 'n'); // Printer: 3939-6257-5463-7739-8658
echo "\n";
echo generateStrongPassword('20', TRUE, 'g'); // Printer: %@#?-?$??-*%@&-?@%#-!%!@
echo "\n";
echo validStrongPassword('vu6QsYz@466V?FxRv*Z4'); // Printer: true
echo "\n";
echo generateRandomPassword(36); // Printer: 3m8GRR-E!bqFz-j%P8dW-sC*h2Q-9fnY88-3Dg%8%