It does not read it in reverse alphabetical order, but in the order it
is listed on the filesystem, which happens to be in reverse alphabetical
order. If you need it ordered, use
$files=array();
if (!($dp = opendir($default_dir))) die("cannot open $default_dir");
while($file = readdir($dp))
is it on a unix system?
if so, do an ls on the system and you will see that the files are listed in
that order.
it is the order in which they were copied to the directory.
try going through a loop before you run your main loop, create an array()
then sort that with some sorting functions and you
2 matches
Mail list logo