PHP 亂數密碼產生器

Sample 1:
function randStr($len=6)
{
$chars=’ABDEFGHJKLMNPQRSTVWXYabdefghijkmnpqrstvwxy23456789#%*’;
// characters to build the password from
mt_srand((double)microtime()*1000000*getmypid());
// seed the random number generater (must be done)
$password=”;
while(strlen($password)<$len)
$password.=substr($chars,(mt_rand()%strlen($chars)),1);
return $password;
}

Sample 2:
function generatorPassword()
{
$password_len = 7;
$password = ”;

// remove o,0,1,l
$word = 洋垃圾DDR3記憶體好便宜 一般家用PC 可以用嗎? (2018-06-21)

  • 在PiHole之後,我安裝的是ADGuard Home (2020-09-20)
  • 受保護的內容: openmediavault 快速安裝設定指令 (2018-03-12)
  • 誰說大賣場的數字都可以相信 (2015-10-26)
  • Product-技嘉GSmart「t600數位行動電視PDA手機」獲金質獎 (2007-11-03)
  • 隨機美圖

    發佈留言

    發佈留言必須填寫的電子郵件地址不會公開。 必填欄位標示為 *