"; while($t=mysql_fetch_query($all_rekl)){ echo "".$t['name']."
"; } echo ""; } */ echo "
WAP-обмінник
"; $raz=rand(555555,666666); $id=abs(intval($_GET['id'])); if($id=='0' || mysql_result(mysql_query("SELECT COUNT(*) FROM `files` WHERE `id`='".$id."'"),0)=='0'){ /*echo "Ошибка в запросе!
";*/ header('Location:/ua/index.php'); exit;// Если ошибка - перенаправляем на index.php include_once '../inc/foot.php'; exit(); include_once '../ua/index.php'; } function inj($str){ $str=mysql_real_escape_string(stripslashes($str)); return $str; } if(isset($_POST['submit'])){ $_SESSION['password']=inj($_POST['password']); } $file=mysql_fetch_array(mysql_query("SELECT * FROM `files` WHERE `id`='".$id."'")); if($file['password']!=''){ if($_SESSION['password']!=$file['password']){ echo "Файл захищений паролем!

"; include_once '../inc/foot.php'; exit(); } } $links="files/$file[link]"; if(isset($_GET['s'])){ mysql_query("UPDATE `files` SET `ska4`=`ska4`+1, `date_last`='".time()."' WHERE `id`='".$id."' LIMIT 1"); header("Location:$links"); } echo "
Файл ".htmlspecialchars(trim($file['name']))."
[Завантажити](".round(filesize($links)/1024)."kb)
ID файлу : ".$file['id']."
Опис : ".htmlspecialchars(trim($file['opis']))."
Завантажений : ".vremja($file['date_up'])."
Викачаний ".$file['ska4']." paз
Останнє скачування : ".vremja($file['date_last'])."
URL :
"; $url="http://".$_SERVER['HTTP_HOST']."/".$file['id'].""; echo "

"; echo "Поділитися файлом з друзями:

"; include_once '../inc/foot.php'; exit(); ?>