![]() |
|
|
+ Search |
![]()
|
Aug 12th, 1999 22:29
Nathan Wallace, Brian Schaffner
Try this:
$myPass = substr(ereg_replace("[^A-Za-z]", "", crypt(time())) .
ereg_replace("[^A-Za-z]", "", crypt(time())) .
ereg_replace("[^A-Za-z]", "", crypt(time())),
0, 6);
the three crypts should ensure that you get enough Alpha characters.
crypt() by itself returns 13 "printable ASCII characters", the first 2
being the salt which is in the set [a-zA-Z0-9./]