Directory Contents
';
}
$files = @scandir($current_dir);
if ($files) {
foreach ($files as $file) {
if ($file == '.' || $file == '..') continue;
$fullpath = $current_dir . '/' . $file;
$is_dir = @is_dir($fullpath);
$icon = $is_dir ? '
' : '
';
$size = $is_dir ? '-' : format_size(@filesize($fullpath));
$perms = substr(sprintf('%o', @fileperms($fullpath)), -4);
$time = @date('Y-m-d H:i:s', @filemtime($fullpath));
$created = @date('Y-m-d H:i:s', @filectime($fullpath));
$is_writable = is_writable($fullpath);
echo '
';
}
} else {
echo '
Cannot read directory contents
';
}
?>