i want to sord the files / folders alphabetically and sord by accending order and by decending order..
can some one help me.
<?
$path = "";
$dir_handle = @opendir($path) or die("Unable to open $path");
echo "Directory Listing of $path<br/>";
while($file = readdir($dir_handle)) {
if(is_dir($file)) {
continue;
}
else if($file != '.' && $file != '..') {
echo "<a href='$path/$file'>$file</a><br/>";
}
}
//closing the directory
closedir($dir_handle);
?>
Edited by electriic ink, 01 May 2006 - 12:07 PM.
















