How to make Symfony session to never timeout
This is for Symfony 1.2 and sfGuardPlugin, but may be relevant for newer versions (1.3, 1.4, etc).
Setting timeout to false in factories.yml should’ve worked, e.g. like this:
all:
user:
class: myUser
param:
# this should have worked, but did not
timeout: falseBut it didn’t work because I think ‘false’ did not get parsed as literal false.
Anyway, my hackish workaround is to add the following inside myUser.class.php:
class myUser extends sfGuardSecurityUser { public function initialize(sfEventDispatcher $dispatcher, sfStorage $storage, $options = array()) { // disable timeout $options['timeout'] = false; parent::initialize($dispatcher, $storage, $options); } // ... }
Related posts:
Related posts brought to you by Yet Another Related Posts Plugin.
Recent Comments