File size: 2.18Kb
<?php
include('./lite/header.inc.php');
include 'constant.php';
@$cf = $_GET["cf"];
@$lf = $_GET["lf"];
@$size = $_GET["sz"];
@$br = $_GET["br"];
if(preg_match("[http]",$lf)) exit(ERROR_MESAGE);
if(preg_match("[\.\.]",$lf)) exit(ERROR_MESAGE);
if(preg_match("[http]",$cf)) exit(ERROR_MESAGE);
if(preg_match("[\.\.]",$cf)) exit(ERROR_MESAGE);
$cf = str_replace('http://','',$_GET["cf"]);
$lf = str_replace('http://','',$_GET["lf"]);
$lf = str_replace('http','',$_GET["lf"]);
$cf = str_replace('http','',$_GET["cf"]);
$cf = str_replace('..','',$cf);
$cf = str_replace('/','',$cf);
$sz = filesize($lf);
$sz = round($sz/1024,1);
$t = filectime($lf);
$op = @file_get_contents("./about/$cf.txt");
$ck = @file_get_contents("./ck/$cf.dat");
$ckz = @file_get_contents("./ds/$cf.sc");
if($ck == '') $ck = 0;
if(empty($op)) $op = 'Отсутствует';
echo '<small>Файл: <a href="'.$lf.'">'.$cf.'</a><br />
Вес: '.htmlspecialchars($sz).' kb <br />
Дата загрузки: '.date("d.m.y",$t).'<br />
Скачан: '.$ckz.' раз <br />';
if(file_exists('scr/'.$cf.'.png')) {
echo "Скриншот:<br /><img src=\"scr/$cf.png\" alt\"\" /><br />"; }
echo ' Описание:<br /> '.htmlspecialchars($op).'<br />';
if(stristr($cf,'.zip')) {
echo '<small><a href="zip.php?lf='.$lf.'&cf='.$cf.'&br='.str_replace('..','',$br).'">Просмотреть содержимое архива</a></small><br />';
}
if(stristr($cf,'.jar')) {
echo '<small><img src="file.png" alt=""/> <a href="jad.php?lf='.$lf.'&cf='.$cf.'&br='.str_replace('..','',$br).'"><b>Скачать jad</b></a></small><br />
<img src="ic.php?lf='.$lf.'" alt=""/> <br />';
}
echo '<a href="comm.php?cf='.$cf.'&lf='.$lf.'&br='.str_replace('..','',$br).'">Комментарии</a></small>'; echo ' <small>['.htmlspecialchars($ck).']</small>';
@include 'ocenf.php';
echo '<hr><small>Скопировать адрес:</small>
<br />
<input tupe="text" value="http://mch-x.net/dl/'.$lf.'"
<br />';
echo '<hr><small><a href="index.php?a='.str_replace('..','',$br).'">К разделам</a></small>';
include('./lite/footer.inc.php');
?>