//////////////////////////////////////////////////////////// // Подсчет папок в папке // //////////////////////////////////////////////////////////// function dir_count($dir = '') { global $realtime; if (is_dir($dir)) { if ($opendir = opendir($dir)) { while (false !== ($file = readdir($opendir))) { if ($file != "." && $file != "..") { if (is_dir($dir . "/" . $file)) { $ex = filemtime($dir . "/" . $file); if ($ex > ($realtime - 259200)) { $count_new++; } $count++; } } } } } if ($count_new) { return $count . ' / +' . $count_new . ''; } else { return $count; } }