Просмотр поста

.
Бермудский
Треугольник

bravay, Вот для разнообразия еще вариант

<?php

/**
 * @package     JohnCMS
 * @link        http://johncms.com
 * @copyright   Copyright (C) 2008-2011 JohnCMS Community
 * @license     LICENSE.txt (see attached file)
 * @version     VERSION.txt (see attached file)
 * @author      http://johncms.com/about
 */

define('_IN_JOHNCMS', 1);

$rootpath = '';
require('incfiles/core.php');
$referer = isset($_SERVER['HTTP_REFERER']) ? htmlspecialchars($_SERVER['HTTP_REFERER']) : core::$system_set['homeurl'];

if (isset($_POST['submit'])) {
    setcookie('cuid', '');
    setcookie('cups', '');
    session_destroy();
    header('Location: index.php');
} else {
    require('incfiles/head.php');
    echo'<div class="rmenu">' .
        '<p>Вы действительно хотите покинуть сайт?<br/><span class="red"><a href="' . $referer . '"><b>ДА</b></a></span> / <span class="green"><a href="../index.php"><b>НЕТ</b></a></span></div>';
    require('incfiles/end.php');
}
Работает!