Файл: mobile/func/wwwredirect.delete.php
Строк: 42
<?php
if (empty($_GET['sok'])) {
    echo '<div style="text-align:center">' . "n";
    echo 'Вы действительно хотите удалить редирект ' . htmlentities($_GET['elid'], ENT_QUOTES, 'UTF-8') . '?<br />' . "n";
    echo '<a href="?func=wwwredirect.delete&elid=' . urlencode($_GET['elid']);
    if (isset($_GET['plid'])) {
        echo '&plid=' . urlencode($_GET['plid']);
    }
    echo '&sok=yes">Да</a> / <a href="?func=wwwredirect';
    if (isset($_GET['plid'])) {
        echo '&elid=' . urlencode($_GET['plid']);
    }
    echo '">Нет</a>' . "n";
    echo '</div>' . "n";
} else {
    $content = api_query('https://' . $server . '/manager/ispmgr?func=wwwredirect.delete&elid=' . urlencode($_GET['elid']) . '&out=xml&auth=' . urlencode($_SESSION['auth']));
    $parse_xml = simplexml_load_string($content);
    if (isset($parse_xml->ok)) {
        echo '<div style="text-align:center">' . "n";
        echo 'Редирект успешно удален!<br />' . "n";
        echo 'Подождите несколько секунд, для перезагрузки сервера, и нажмите "продолжить".<br />' . "n";
        echo '<a href="?func=wwwredirect';
        if (isset($_GET['plid'])) {
            echo '&elid=' . urlencode($_GET['plid']);
        }
        echo '">Продолжить»</a>' . "n";
        echo '</div>' . "n";
        api_query('https://' . $server . '/manager/ispmgr?func=restart&auth=' . urlencode($_SESSION['auth']));
    } else {
        echo '<div style="text-align:center">' . "n";
        echo 'Ошибка при удалении редиректа!<br />' . "n";
        echo '<a href="?func=wwwredirect';
        if (isset($_GET['plid'])) {
            echo '&elid=' . urlencode($_GET['plid']);
        }
        echo '">Продолжить»</a>' . "n";
        echo '</div>' . "n";
    }
}
?>