150){$arsize=150;} // se limita arsize a 300
for($i=0;$i<$arsize;$i++) {
$icon = 'unknown.png';
$ext = strtolower(substr($files[$i], strrpos($files[$i], '.')+1));
$supportedimages = array('gif', 'png', 'jpeg', 'jpg');
$thumb = '';
if($showthumbnails && in_array($ext, $supportedimages)) {
$thumb = '
!['.$files[$i].'](dlf/trans.gif)
';
$thumb2 = ' onmouseover="o('.$i.', \''.urlencode($leadon . $files[$i]).'\');" onmouseout="f('.$i.');"';
}
if($filetypes[$ext]) {
$icon = $filetypes[$ext];
}
$filename = $files[$i];
if(strlen($filename)>62) {
$filename = substr($files[$i], 0, 62) . '...';
}
$fileurl = $leadon . $files[$i];
if($forcedownloads) {
$fileurl = $_SESSION['PHP_SELF'] . '?dir=' . urlencode($leadon) . '&download=' . urlencode($files[$i]);
}
$altex=file_get_contents('./dlf/'.$files[$i].'.txt');
$tamanio = filesize($leadon.$files[$i]);
if ($tamanio > 1024)
{
$resu=round($tamanio/1024) . ' KB';
}
else
{
$resu=$tamanio . ' B ';
}
?>