note 74953 added to function.mt-rand
| From: | Jonathan at jooped dot co dot uk | Date: | Sun, 06 May 2007 03:04:14 +0000 |
| Subject: | note 74953 added to function.mt-rand | ||
| Groups: | php.notes | ||
| Request: | Send a blank email to php-notes+get-126230@lists.php.net to get a copy of this message | ||
An easier password generator than earlsinclair2001.
function easyPassGen($length=10){
$enc = sh1(mt_rand().mt_rand().mt_rand());
$password = sub_str($enc, 1, $length);
return $password;
}
Might help someone (pretty simple though).
----
Server IP: 87.124.64.96
Probable Submitter: 80.89.87.96
----
Manual Page -- http://www.php.net/manual/en/function.mt-rand.php
Edit -- https://master.php.net/note/edit/74953
Del: integrated -- https://master.php.net/note/delete/74953/integrated
Del: useless -- https://master.php.net/note/delete/74953/useless
Del: bad code -- https://master.php.net/note/delete/74953/bad+code
Del: spam -- https://master.php.net/note/delete/74953/spam
Del: non-english -- https://master.php.net/note/delete/74953/non-english
Del: in docs -- https://master.php.net/note/delete/74953/in+docs
Del: other reasons-- https://master.php.net/note/delete/74953
Reject -- https://master.php.net/note/reject/74953
Search -- https://master.php.net/manage/user-notes.php