function getline($file){
$i=0;
do{
$data = file($file);
$num = count($data);
$id = mt_rand(0,$num-1);
$shuju_text = chop($data[$id]);
$i=strlen($shuju_text);
}
while ($i<1);
return $shuju_text;
}
php函数随机读取txt文本中的一行
最新推荐文章于 2022-11-19 09:02:09 发布