View file adm/fnc/deldown.php

File size: 406B
<?
include"../sys/fnc.php";
$d=trim(htmlspecialchars($_GET['d']));
if($d!="")
{
	$dir=opendir("../../download/");
	while($file=readdir($dir))
	{
		if(($file!=".") and ($file!=".."))
		{
			$a[]=$file;
		}
	}
	closedir($dir);

	@chmod("../../download/".$a[$d],0777);
	@unlink("../../download/".$a[$d]);
	echo'<font color="red">Файл '.$a[$d].' успешно удален!</font>';
	
}