
Untitled
By: a guest on
Dec 24th, 2012 | syntax:
None | size: 0.69 KB | hits: 10 | expires: Never
$files = filelist("./",1,1); // call the function
shuffle($files);
foreach ($files as $list) {//print array
echo "<a href="" . $list['name'] . "$startDir"><h4> " . $list['name'] . " </h4></a>";
// echo "Directory: " . $list['dir'] . " => Level: " . $list['level'] . " => Name: " . $list['name'] . " => Path: " . $list['path'] ."<br>";
$counter = 0;
foreach ($files as $list) {//print array
// your loop code here...
$counter++;
if ($counter > 10) break;
}
for($i=0; $i<=14; $i++) {
// echo $file[$i];
}
foreach(array_slice($files, 0, 15) as $file) {
/* your code here */
}
foreach (array_rand($files, 15) as $key) {
$file = $files[$key];
// Your code here
}