0 ? $monthname[intval($parts[1])] : '', $parts[0], count($parts) > 5 ? "$parts[3]:$parts[4]" : '', ])); } function showsize($bytes) { $units = ['', 'k', 'M', 'G', 'T']; $log = strlen($bytes) - 1; $order = floor($log / 3); if (!isset($units[$order])) return $bytes; return implode(' ', [ number_format($bytes / (1000 ** $order), $log % 3 ? 0 : 1, ',', ''), $units[$order], ]); } function showlink($title, $href) { return empty($href) ? $title : sprintf('%s', $href, $title); }