Add-on Online Status Timeout

Is anyone able to do this in Xenforo 1.5? I'd like to increase the time to 2 hours like I had in vbulletin. Any help would be appreciated. :-)
 
Online Status Timeout is just time, in which set cookie with session_id.
This time in code, XenForo_Session (\library\XenForo\Session.php)
Find this code:
Code:
public function __construct(array $config = array(), Zend_Cache_Core $cache = null, Zend_Db_Adapter_Abstract $db = null)
    {
        if (empty($config['admin']))
        {
            $defaultConfig = array(
                'table' => 'xf_session',
                'cacheName' => 'session',
                'cookie' => 'session',
                'lifetime' => 3600
            );
        }
        else
        {
            $defaultConfig = array(
                'table' => 'xf_session_admin',
                'cacheName' => 'session_admin',
                'cookie' => 'session_admin',
                'lifetime' => (XenForo_Application::debugMode() ? 86400 : 3600) // longer lifetime in debug mode to get in the way less
            );
            unset($config['admin']);
        }
'lifetime' => 3600 - it is what You need. Just change 3600 to You time.
As for addon for this, I dont know how to extends this class so can not make addon.

So, basically, change the 3600 in both instances of this code and it will work? Thanks in advance. :-)
 
Top Bottom