ok...but for now i had done this....
this will run every time when the user clicks a new action
if ($this->session->__isset('auth')) {
$time = time() - $auth['time'];
if ($time >= 20 && !$auth['remember']) {
$this->session->set('auth', array(
'id' => $auth['id'],
'name' => $auth['name'],
'user' => $auth['user'],
'time' => time(),
'remember' => $auth['remember'],
));
$dispatcher->forward(array(
'controller' => 'session',
'action' => 'end'
));
return false;
} else {
$this->session->set('auth', array(
'id' => $auth['id'],
'name' => $auth['name'],
'user' => $auth['user'],
'time' => time(),
'remember' => $auth['remember'],
));
}
}