PHP 简易版生成随机码

<?php

function makeRandomCount($length = 6){
$key = “”;
$str = ’0123456789ABCDEFGHIJKLOMNOPQRSTUVWXYZ’;//字符池
for($i=0;$i<$length;$i++) {
$key .= $str{mt_rand(0,36)};
}
return $key;
}

?>
原文地址:https://www.cnblogs.com/rmbteam/p/2205350.html