PHP code example of visionbites / password-policy

1. Go to this page and download the library: Download visionbites/password-policy 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/ */

    

visionbites / password-policy example snippets


'visionbites.password-policy.password_regex' => '/^(?=.*[0-9])(?=.*[!@#$%^&*])[A-Za-z\d!@#$%^&*]{16,}$/'

// in site/languages/de.php

return [
  'translations' => [
    'visionbites.password-policy.error-message' => 'Das Passwort muss mindestens 16 Zeichen lang sein und eine Zahl und ein Sonderzeichen enthalten.',
  ]
];