File size: 774B
<?php
include_once '../../sman/includs/configurations.php';
include_once '../../sman/includs/head.php';
if (isset($_GET['path'])) {
echo '<center>Вы подтверждаете удаление файла? <a href = "?path_to='.htmlspecialchars($_GET['path']).'">да</a> / <a href = "/sman/'.FILE_OPT.'.php?path='.$back.'">нет</a></center>';
} else if (isset($_GET['path_to'])) {
$path_file = htmlspecialchars($_GET['path_to']);
if (unlink(ROOT.$path_file))
$delete = '<span style = "color: green;">Удалено</span>';
else
$delete = '<span style = "color: red;">Ошибка!</span>';
echo $path_file.' - '.$delete.' <br />';
} else {
header("Location: /sman/index.php");
exit;
}
include_once '../../sman/includs/foot.php';
?>