Refresh list
[ok] ' . $filename . '';
} else {
// Increment missing count
$missingCount++;
// Display [missing] in red for non-matching files
$files[] = '[missing] ' . $filename;
}
}
// Iterate over the files in the current directory
foreach (scandir($currentDir) as $filename) {
// Exclude hidden files, directories, and z_listcheck.php
if ($filename[0] === '.' || is_dir($filename) || $filename === 'z_listcheck.php' ) {
continue;
}
// Exclude "error_log" and "alceawis.de.zip" files
if ($filename === 'error_log' || $filename === 'alceawis.de.zip') {
continue;
}
// Check if the file is listed in the z_list.txt report
if (!in_array($filename, $reportFiles)) {
// Increment file count
$fileCount++;
// Increment missing count
$missingCount++;
// Display [missing] in red for non-listed files
$files[] = '[missing] ' . $filename;
}
}
// Display folders
foreach ($folders as $folder) {
echo '[ok] ' . $folder . '
';
}
// Display files
foreach ($files as $file) {
echo $file . '
';
}
echo 'Total Files: ' . $fileCount . ' Total Folders: ' . $folderCount . '
';
echo '
';
// Display the count of [ok] and missing files
echo 'Number [ok]: ' . $okCount;
if ($okCount === $fileCount) {
echo ' (all)';
}
echo '
';
echo 'Number of missing: ' . $missingCount . '
';
?>