How often do the files in the directory change?
If it is not very often, you could run a cron job to put the list of files or a subset of the list of files into a separate file, then obtain your 5 file names from that.
In reply to Re: quick way to read a few directory entries of many
by kgraff
in thread quick way to read a few directory entries of many
by leocharre
| For: | Use: | ||
| & | & | ||
| < | < | ||
| > | > | ||
| [ | [ | ||
| ] | ] |