1:
2:
3:
4:
5:
6:
7:
8:
9:
10:
11:
12:
13:
14: | /** generriert ein zufalls password **/
function RandomPassword() {
for($i=0;$i<8;$i++) {
$j = mt_rand(0,53);
if($j<26)$hash .= chr(rand(65,90));
else if($j<52)$hash .= chr(rand(97,122));
else if($j<53)$hash .= '.';
else $hash .= '/';
}
$str = crypt(time(),$hash);
$str = str_replace("/", "", $str);
$str = str_replace(".", "", $str);
return $str;
} |