im reading a directory and echoing contents of each txt file in that dir...
how can i read txt files in alphabetical order?
my code...
$path = "./$sub/";
$handle = dir($path);
while ($file = $handle->read()) {
if (eregi(".txt$", $file)) {
$f = file($path.$file);
echo"$f[1] $f[2] etc etc";
}
}
cheers
J