View file down/tipes/jar.php

File size: 1.76Kb
<?
echo "<div class='contur'><div class='header'>";



echo $i+1;
echo ". $filename<br />\n";
echo"<img src=\"$l/$filename.gif\" alt=\"scr\" /><br/>";
if (is_file("$l/$file.opis"))
{
$opis=file("$l/$file.opis");
$opis=implode("",$opis);

$opis=str_replace("\r\n","<br />",$opis);
$opis=str_replace("\r","<br />",$opis);
$opis=str_replace("\n","<br />",$opis);
echo "Описание:<br />$opis<br />\n";
}
else
{
echo "Описание: Отсутствует<br />\n";
}

$jad_file=str_replace('.jar','.jad', "$l/$file");
if ($setall['loads']==0 || !empty($_SESSION['login']))
{
if (is_file("$jad_file"))
{
echo "<a href=\"down.php?file=$link2\">Скачать jad</a><br />\n";
}

echo "<a href=\"index.php?l=$prl$filename\">Скачать jar</a><br />\n";
}

$filesize=filesize("$l/$file");
$filesize_ed='B';
if ($filesize>=1024)
{
$filesize= round($filesize/1024 , 2);
$filesize_ed='KB';
}
if ($filesize>=1024)
{
$filesize= round($filesize/1024 , 2);
$filesize_ed='MB';
}

echo "Размер: <font color='red'>$filesize $filesize_ed</font><br />";



$q = mysql_query("SELECT COUNT(*) FROM `loads_komm` WHERE `file` = '$prl$file';");
echo "<a href=\"komm.php?file=$prl$file\">Комментарии</a>(". mysql_result($q, 0).") ";

$q = mysql_query("SELECT COUNT(*) FROM `downloads` WHERE `file` = '$prl$file';");
echo "<br/>Скачивали: <b>". mysql_result($q, 0)."</b> раз.<br />\n";
if ($qw['type']=="999" && $r=="ok")
{
$prl_2=ereg_replace("/$","",$prl);
$prl_2=ereg_replace("^/","",$prl_2);
echo "[<a href=\"dir.php?l=$prl_2&amp;set=$file&amp;act=del\">Удалить</a>]";
echo "[<a href=\"dir.php?l=$prl_2&amp;set=$file&amp;act=set&amp;page=$page\">Параметры</a>]";
}
echo "</div>\n";
echo "</div>\n";
?>