更新时间:2023-01-29 17:39:26
PHP具有 rand()函数:
$int= rand(1262055681,1262055681);
它还具有 mt_rand(),这通常被认为在结果中具有更好的随机性:
It also has mt_rand(), which is generally purported to have better randomness in the results:
$int= mt_rand(1262055681,1262055681);
要将时间戳记转换为字符串,可以使用 date(),即:
To turn a timestamp into a string, you can use date(), ie:
$string = date("Y-m-d H:i:s",$int);