Jump to content

jazzzz

New Members
  • Content Count

    1
  • Joined

  • Last visited

Community Reputation

0 Neutral

About jazzzz

  • Rank
    Newbie
  1. $dir_name="./$masterdir"; $dir = opendir($dir_name); $basename = basename($dir_name); $fileArr = array(); while ($file_name = readdir($dir)){ if (preg_match("/\.jpg$/i", $file_name)) { #Get file modification date... # $fName = "$dir_name/$file_name"; $fTime = filemtime($fName); $fileArr[$file_name] = $fTime; } } # Use arsort to get most recent first # and asort to get oldest first arsort($fileArr); ////$numberOfFiles = sizeOf($fileArr); $numberOfFiles =7; for($t=0;$t<$numberOfFiles;$t++){ $thisFile = each($fileArr); $thisName = $thisFile[0]; $thisTime = $thisFile[1]; $thisTime = date("d
×
×
  • Create New...

Important Information

We have placed cookies on your device to help make this website better. You can adjust your cookie settings, otherwise we'll assume you're okay to continue.