// Calculate donation string
    if (SC::isEmpty('userdata.user_donate_time')) {
        $donated = 'did not donate';
    } else {
        $donated = SC::get('board_config.time_now') - SC::get('userdata.user_donate_time') <= 2678400 ? 'donated' : 'did not donate';
    }
} else {
    $age = $gender = $reg_date = $user_id = $donated = 'not registered';
    $orig_user_id = -1;
}
$gold_granted = FALSE;
/* check for gold grant */
if (($gold_amount = SC::get('goldinfo')) != NULL) {
    $gold_granted = TRUE;
} elseif (($gold_amount = session_get('goldinfo')) != NULL) {
    session_remove('goldinfo');
    $gold_granted = TRUE;
}
$events = $products = '';
$evars = $evar1 = $evar7 = '';
if ($gold_granted) {
    $gold_amount = preg_replace('/^.+?\\b(\\d+) gold.+$/', '$1', $gold_amount['message']);
    $events = "event5";
    $products = "virtual;gold grant;;;event5={$gold_amount}";
}
$omniture =& SC::get('omniture');
// Registration events
if ($omniture && array_key_exists('event', $omniture)) {
    if (!empty($events)) {
        $events .= ',';
    }
Beispiel #2
0
 public function loadFromSession($nonce)
 {
     $key = $nonce . '_error_model_data';
     $this->_data = session_get($key, SC::get('userdata.user_id'));
     session_remove($key, SC::get('userdata.user_id'));
 }
Beispiel #3
0
 // $dbh is global.
 if (!$dbh) {
     die("Fatal: Backend DB not connected.");
 }
 $time_start = microtime_float();
 if ($_REQUEST['phpinfo']) {
     ob_start();
     phpinfo();
     $sqldr = '<div style="font-size:130%">' . ob_get_clean() . '</div>';
 } else {
     if (isset($_SESSION['s_PROXY']) && !isset($DB['db'])) {
         session_remove('s_PROXY');
         $s_db = session_remove('s_DB');
         $s_query = session_remove('s_QUERY');
         $s_id = session_remove('s_ID');
         $s_table = session_remove('s_TABLE');
         /*
          * Execute query (proxy db)
          */
         $keys = array_keys($_POST);
         if (strstr($keys[0], "cryptdb") == FALSE) {
             die("Parse error");
         }
         $index = $keys[0][0];
         $fieldname = preg_split("/\\&/", $s_id);
         //Using hardocded default. If user inputs 'localhost' mysqli ignores port...
         $host = ini_get("mysqli.default_host");
         //$database = ini_get("mysqli.default_database");
         $user = isset($CRYPTDB['user']) ? $CRYPTDB['user'] : ini_get("mysqli.default_user");
         // Force default
         $port = ini_get("mysqli.default_port");
Beispiel #4
0
<?php

    session_remove('id');
    session_remove('logged_in');
    session_remove('username');
    session_remove('admin');

    $_SESSION['logged_out'] = TRUE;

    header('location: /accounts/login');
    exit;