Beispiel #1
0
function operate_session()
{
    if (check_session() === FALSE) {
        // session is not good
        fermer_session();
        // destroy it
    } else {
        // Restore data lost if possible
        foreach ($_SESSION as $key => $value) {
            if (substr($key, 0, 8) === 'BT-post-') {
                $_POST[substr($key, 8)] = $value;
                unset($_SESSION[$key]);
            }
        }
        return TRUE;
    }
}
Beispiel #2
0
<?php

# *** LICENSE ***
# This file is part of BlogoText.
# http://lehollandaisvolant.net/blogotext/
#
# 2006      Frederic Nassar.
# 2010-2013 Timo Van Neerden <*****@*****.**>
#
# BlogoText is free software.
# You can redistribute it under the terms of the MIT / X11 Licence.
#
# *** LICENSE ***
$GLOBALS['BT_ROOT_PATH'] = '../';
require_once '../inc/inc.php';
error_reporting($GLOBALS['show_errors']);
operate_session();
fermer_session();