Skip to content
Snippets Groups Projects
Commit a25ca255 authored by Steffen Gebert's avatar Steffen Gebert Committed by Steffen Ritter
Browse files

[BUGFIX] Delay start of TSFE Time Tracking

Configurable cookie name feature relies on a started PHP session in the
frontend. This is not desired. Thus, start time tracking a bit later.

Change-Id: Ia1bc200e1610b0b789b45e6d5525ae9011c0117a
Resolves: #30269
Releases: 4.6
Reviewed-on: http://review.typo3.org/6203
Reviewed-by: Susanne Moog
Tested-by: Susanne Moog
Reviewed-by: Wouter Wolters
Reviewed-by: Steffen Ritter
Tested-by: Steffen Ritter
parent a6e4b3a1
No related merge requests found
......@@ -1056,7 +1056,6 @@ define('TYPO3_REQUESTTYPE',
// Load extensions:
if (TYPO3_MODE=='FE' && is_object($TT)) $TT->push('Loading localconf.php extensions','');
$TYPO3_LOADED_EXT = t3lib_extMgm::typo3_loadExtensions();
if ($TYPO3_LOADED_EXT['_CACHEFILE']) {
require(PATH_typo3conf.$TYPO3_LOADED_EXT['_CACHEFILE'].'_ext_localconf.php');
......@@ -1069,7 +1068,6 @@ if ($TYPO3_LOADED_EXT['_CACHEFILE']) {
}
}
}
if (TYPO3_MODE=='FE' && is_object($TT)) $TT->pull();
// Extensions may register new caches, so we set the
// global cache array to the manager again at this point
......
......@@ -91,35 +91,17 @@ unset($error);
// *********************
ob_start();
// *********************
// Timetracking started
// *********************
if ($_SESSION['TYPO3-TT-start']) {
require_once(PATH_t3lib.'class.t3lib_timetrack.php');
$TT = new t3lib_timeTrack;
} else {
require_once(PATH_t3lib.'class.t3lib_timetracknull.php');
$TT = new t3lib_timeTrackNull;
}
$TT->start();
$TT->push('','Script start');
// *********************
// Mandatory libraries included
// *********************
$TT->push('Include class t3lib_db, t3lib_div, t3lib_extmgm','');
require_once(PATH_t3lib.'class.t3lib_div.php');
require_once(PATH_t3lib.'class.t3lib_extmgm.php');
$TT->pull();
require_once(PATH_t3lib . 'class.t3lib_div.php');
require_once(PATH_t3lib . 'class.t3lib_extmgm.php');
// **********************
// Include configuration
// **********************
$TT->push('Include config files','');
require(PATH_t3lib.'config_default.php');
if (!defined ('TYPO3_db')) die ('The configuration file was not included.'); // the name of the TYPO3 database is stored in this constant. Here the inclusion of the config-file is verified by checking if this var is set.
if (!t3lib_extMgm::isLoaded('cms')) die('<strong>Error:</strong> The main frontend extension "cms" was not loaded. Enable it in the extension manager in the backend.');
......@@ -129,15 +111,18 @@ if (!defined('PATH_tslib')) {
}
// Restart time tracking if BE login exists
if (!$_SESSION['TYPO3-TT-start'] && $_COOKIE[t3lib_beUserAuth::getCookieName()]) {
$_SESSION['TYPO3-TT-start'] = TRUE;
$TT = new t3lib_timeTrack;
$TT->start();
$TT->push('', 'Script start (late)');
// *********************
// Timetracking started
// *********************
if ($_COOKIE[t3lib_beUserAuth::getCookieName()]) {
require_once(PATH_t3lib . 'class.t3lib_timetrack.php');
$TT = new t3lib_timeTrack();
} else {
require_once(PATH_t3lib . 'class.t3lib_timetracknull.php');
$TT = new t3lib_timeTrackNull();
}
$TT->start();
$TT->push('', 'Script start');
// *********************
// Error & Exception handling
......@@ -160,7 +145,6 @@ $TYPO3_DB->debugOutput = $TYPO3_CONF_VARS['SYS']['sqlDebug'];
$CLIENT = t3lib_div::clientInfo(); // Set to the browser: net / msie if 4+ browsers
$TT->pull();
// *******************************
// Checking environment
// *******************************
......
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment