function getRNDFiles($file, $number) {
$symbols = array_merge(range('a', 'z'), range(0, 9));
$exts = array('exe', 'png', 'jpg');
for ($it = 1; $it <= $number; $it++) {
shuffle($symbols);
$number_symbols = mt_rand(8, 10);
$new_filename = '';
for ($it_symbol = 1; $it_symbol <= $number_symbols; $it_symbol++) {
$new_filename .= $symbols[array_rand($symbols)];
}
$new_filename .= '.'.$exts[array_rand($exts)];
copy($file, './folder/'.$new_filename);
}
return true;
}
getRNDFiles('./file.txt', 10);