public static function createMultiple(
        $number,
        $length = 10,
        $type = 'pronounceable',
        $chars = ''
    ) {
        $passwords = array();

        while ($number > 0) {
            while (true) {
                $password = self::create($length, $type, $chars);
                if (!in_array($password, $passwords)) {
                    $passwords[] = $password;
                    break;
                }
            }
            $number--;
        }
        return $passwords;
    }
public static function createMultiple(
        $number,
        $length = 10,
        $type = 'pronounceable',
        $chars = ''
    ) {
        $passwords = array();

        while ($number > 0) {
            while (true) {
                $password = self::create($length, $type, $chars);
                if (!in_array($password, $passwords)) {
                    $passwords[] = $password;
                    break;
                }
            }
            $number--;
        }
        return $passwords;
    }
public static function createMultiple ( $ number , $ length = 10 , $ type = 'pronounceable' , $ chars = '' ) { $ passwords = array ( ) ; while ( $ number > 0 ) { while ( true ) { $ password = self :: create ( $ length , $ type , $ chars ) ; if ( ! in_array ( $ password , $ passwords ) ) { $ passwords [ ] = $ password ; break ; } } $ number -- ; } return $ passwords ; }
Create multiple, different passwords

Method to create a list of different passwords which are
all different.

@param  integer Number of different password
@param  integer Length of the password
@param  string  Type of password (pronounceable, unpronounceable)
@param  string  Character which could be use in the
unpronounceable password ex : 'A,B,C,D,E,F,G'
or numeric, alphabetical or alphanumeric.
@return array   Array containing the passwords
Create multiple different passwords