ok, im having some problems here. I got my little script to find the files in the DIr load it into an array and then print them but i cann't get CASE_LOWEr to work so it will sort them all as lowercase and in order. Here's the script:
<?PHP
//sets a variable as the DIR path
//$the_path = ""
#sets variable $handle as the DIR path
$handle = dir($the_path);
#LOOPS= set $file equal to a read DIR path
while ($file = $handle->read())
{
if (($file != ".") && ($file != ".."))
//start array
{
//gets file size
$size = filesize($file);
//prints just a list + fiel size
print "<a href=\" ". $the_path . $file."\"target=\"_new\" class=\"links\">" . $file . "</a> - " . $size . "<br>";
};
}
// fill an array with all items from a directory
$handle = opendir('.');
while ($filearray = readdir($handle))
{
$filesarray[] = $filearray;
}
closedir($handle);
//break a line or three
echo "<br><br>...<br>";
//uppercase ABC then lower case ABC
sort($filesarray);
//prints array as 1 line
print_r($filesarray);
//break a line or three
echo "<br><br>...<br>";
//trying to make the array lower case
print_r(array_change_key_case($filesarray, CASE_LOWER));
//uppercase ABC then lower case ABC
sort($filesarray);
//prints array as 1 line but as all lowercase
print_r($filesarray);
//end php
?>
thasnks for any help