Firstly there is a function in the file system called stat();
which chucks out an array. (Read the Manual on stat(); )
basically you should have some sort of loop, probably a while loop, which will first get all the files in your site, than create a new array which holds the filename and the last modified date and any other information you wish for the array.
Then im not sure, maybe an array_sort() could do the trick.
Id be more helpful but i dont have any examples to show.