Index: trunk/kernel/include/usersession.php =================================================================== diff -u -N -r5218 -r5431 --- trunk/kernel/include/usersession.php (.../usersession.php) (revision 5218) +++ trunk/kernel/include/usersession.php (.../usersession.php) (revision 5431) @@ -475,6 +475,7 @@ { $application =& kApplication::Instance(); $application->setVisitField('PortalUserId', $this->Get('PortalUserId') ); + $application->SetVar('u_id', $this->Get('PortalUserId')); } // unset($this->CurrentUser); @@ -510,20 +511,19 @@ $extra_groups = implode(',', $GroupList); $this->SetVariable('UserGroups', $extra_groups); - + $this->Set('GroupId', $PersonalGroup ? $PersonalGroup : $PrimaryGroup); $this->Set('GroupList', $extra_groups); $this->SetVariable('UserGroups', $this->Get('GroupList') ); - if( class_exists('kApplication') ) - { - $app = kApplication::Instance(); - $kSession = $app->recallObject('Session'); - $kSession->SetField('GroupList', $extra_groups); - $app->StoreVar('UserGroups', $this->Get('GroupList') ); - $app->setVisitField('PortalUserId', $this->Get('PortalUserId') ); - } + + $app = kApplication::Instance(); + $kSession = $app->recallObject('Session'); + $kSession->SetField('GroupList', $extra_groups); + $app->StoreVar('UserGroups', $this->Get('GroupList') ); + $app->setVisitField('PortalUserId', $this->Get('PortalUserId') ); + $this->Set('LastAccessed', adodb_date('U') ); $this_login = $this->GetPersistantVariable("ThisLogin");