0 //if ($sessionId > 0) //{ $cacheKey = "debrief_" . intval($userId); $cached = cache_get($sessionId, $cacheKey); if ($cached !== null) { print_r($cached); } else { $stats = new StatsObject($db); $stats->getStatsForSession($sessionId, $userId); $stats_arr = $stats->getResultArray(true, "Stats_Collected_OK"); $json = json_encode($stats_arr); cache_put($sessionId, $cacheKey, $json); print_r($json); // OK } //} //else trigger_error("Invalid session id"); ?>