经测试代码如下:
/**
* 生成随机密码
*
* @param
* @arrange (512.笔记) jb51.cc
**/
function makepass() {
$cons = "bcdfghjklmnpqrstvwxyz";
$vocs = "aeIoU";
for ($x=0; $x < 6; $x++) {
mt_srand ((double) microtime() * 1000000);
$con[$x] = substr($cons,mt_rand(0,strlen($cons)-1),1);
$voc[$x] = substr($vocs,strlen($vocs)-1),1);
}
$makepass = $con[0] . $voc[0] .$con[2] . $con[1] . $voc[1] . $con[3];
return $makepass;
}
/*** 来自编程之家 jb51.cc(jb51.cc) ***/
原文链接:https://www.f2er.com/php/528890.html