Hello everyone,
I am trying to do the integration and it works with buggies elements.
I modified the /manager/include/config.inc.php and the startCMSSession() with the following below.
// start cms session
if(!function_exists('startCMSSession')) {
function startCMSSession(){
global $site_sessionname;
session_name($site_sessionname);
include_once 'assets/libphp/adodb/session/adodb-session2.php';
$adodbOptions = array();
$adodbOptions['table'] = 'client_sessions2';
$adodbOptions['debug'] = false;
ADOdb_Session::config('mydriver', 'myserver', 'mydbuser', 'mydbpassword', 'mydbname', $adodbOptions);
ADOdb_Session::Persist($connectMode=false);
session_start();
$cookieExpiration= 0;
if (isset ($_SESSION['mgrValidated']) || isset ($_SESSION['webValidated'])) {
$contextKey= isset ($_SESSION['mgrValidated']) ? 'mgr' : 'web';
if (isset ($_SESSION['modx.' . $contextKey . '.session.cookie.lifetime']) && is_numeric($_SESSION['modx.' . $contextKey . '.session.cookie.lifetime'])) {
$cookieLifetime= intval($_SESSION['modx.' . $contextKey . '.session.cookie.lifetime']);
}
if ($cookieLifetime) {
$cookieExpiration= time() + $cookieLifetime + 60*60*24*5; //5 jours entiers + temps de validité par défaut
}
if (!isset($_SESSION['modx.session.created.time'])) {
$_SESSION['modx.session.created.time'] = time();
}
}
setcookie(session_name(), session_id(), $cookieExpiration, MODX_BASE_URL);
}
}
Now some features are really not working well:
- login in manager...
- captcha codes...
I will try to do it with plugins and MODx events.