How do I check the total number of files in a folder?
I want to use a loop to list the file names in a folder. How do I find out the total number of files in the folder so I know when to end the loop? I can't use 'file exists' because the file names could be anything.
requesting the lenght of the array will get you the number of files.
and to go through all these files:
[code]
for($j=0; $j<(count($files)-1); $j++)
{
echo ($files[$j]);
}
?>