php llast create file name code example
Example: php get latest file in directory
$files = scandir('data', SCANDIR_SORT_DESCENDING);
$newest_file = $files[0];
$files = scandir('data', SCANDIR_SORT_DESCENDING);
$newest_file = $files[0];