If anyone runs PHP on their local machine this code will generate the output like I did:
PHP Code:
<?php
$dir = "c:\\games\\tsf\\cache\\";
// Open a known directory, and proceed to read its contents
if (is_dir($dir)) {
if ($dh = opendir($dir)) {
while (($file = readdir($dh)) !== false) {
if (substr($file, -4) == ".j2l") {
$lastModified = filemtime($dir . $file);
$date = date("m/d/Y h:i a", $lastModified);
$fp = fopen($dir . $file, "r");
fseek($fp, 188);
$levelname = trim(fgets($fp, 32));
printf("%-30s%-23s%s\n", $file, $date, $levelname);
}
}
closedir($dh);
}
}
?>
|