$value) { $key++; $kansiot[$key] = $value; } } $cnt = 0; foreach($kansiot AS $key => $value) { $root .= $value."/"; if($value) $displayroot .= $value."/"; unset($dest); if ($dir = @opendir("$root")) { $x=0; while (($file = readdir($dir)) !== false) { $destination = $root."/".$file; if(is_dir($destination) AND $file!="." AND $file!="..") { $dest[$x++] = $file; } } $swp=0; if($dest) { natcasesort($dest); foreach($dest as $directory) { $directory_list[$cnt] = $displayroot.$directory; $directory_inset[$displayroot.$directory] = $key; $cnt++; } } } closedir($dir); } $root = $relative_root; $root .= $selected_dir; unset($dest); if ($dir = @opendir("$root")) { $x=0; while (($file = readdir($dir)) !== false) { $destination = $root."/".$file; if(is_file($destination) AND $file!="." AND $file!="..") { $dest[$x++] = $file; } } $swp=0; if($dest) { natcasesort($dest); foreach($dest as $file) { $file_list[$cnt] = $file; $cnt++; } } } closedir($dir); ?> Kuusamo Hirsitalot - Extranet
$allowed) { ?>
 
.. / "; $display_path = explode("/",$selected_dir); $cnt=0; foreach($display_path AS $path) { if($cnt) $url_path .= "/"; if($cnt) print " / "; $url_path .= $path; print "$path"; $cnt++; } ?>
Luettelo ja tiedot Esikatselukuvat
"; } else { $link = "index.php?dir"; print ""; } if($directory_list) { natcasesort($directory_list); foreach($directory_list as $directory) { $inset = 22; for($x = 0 ; $x < $directory_inset[$directory] ; $x++) { $inset = $inset+22; } $display_directory = explode("/",$directory); if($selected_dir == $directory) { $link = "index.php?dir=".urlencode($directory); print ""; } else { $link = "index.php?dir=".urlencode($directory); print ""; } } } ?>
..
..
".ereg_replace(" "," ",$display_directory[count($display_directory)-1])."
".ereg_replace(" "," ",$display_directory[count($display_directory)-1])."
  
"; print ""; print ""; print ""; if(file_exists($thumbs_path.$thumbfile)) print ""; else print ""; print ""; } elseif($view=="thumbs") { if(!$cnt) print "
".chunk_split($file,60)."".number_format(($size/1024), 1, '.', ' ')." kt".date ("j.n.Y H:i",$time)."Luo esikatselukuva
"; $cnt++; $sourcefile = $system_root.$selected_dir."/".$file; $thumbfile = filemtime($sourcefile).filesize($sourcefile).$file.".jpg"; $printfile = filemtime($system_root.$selected_dir."/".$file).filesize($system_root.$selected_dir."/".$file).$file.".jpg"; $link = "download.php?file=".urlencode($selected_dir)."%2F".urlencode($file); if(file_exists($thumbs_path.$thumbfile)) print "