Closed Rick1125 closed 10 years ago
$generator = new \Hackzilla\PasswordGenerator\Generator\PasswordGenerator(); $generator->setOptions(self::OPTION_UPPER_CASE | self::OPTION_LOWER_CASE | self::OPTION_NUMBERS); $password = $generator->generatePassword();
use 'self' here doesn't work properly, I guess it will be PasswordGenerator::OPTION_UPPER_CASE
and I also think you should "use" the class first before using it, like:
use Hackzilla\PasswordGenerator\Generator\PasswordGenerator as PG;
This is a good library, BTW, save me lots of time from reinvent wheel. Thank you very much.
yeah, good point.
Thanks for your feedback.
I've also written a demo app that I haven't yet made mention on in the read me. https://github.com/hackzilla/password-generator-app
$generator = new \Hackzilla\PasswordGenerator\Generator\PasswordGenerator(); $generator->setOptions(self::OPTION_UPPER_CASE | self::OPTION_LOWER_CASE | self::OPTION_NUMBERS); $password = $generator->generatePassword();
use 'self' here doesn't work properly, I guess it will be PasswordGenerator::OPTION_UPPER_CASE
and I also think you should "use" the class first before using it, like:
use Hackzilla\PasswordGenerator\Generator\PasswordGenerator as PG;
This is a good library, BTW, save me lots of time from reinvent wheel. Thank you very much.