Suppose I am in indexAction IndexController. I saved some data in the session. Now I want to clear the entire session when I switch to another controller, say ExampleController. How can i do this?
If you want to delete all session namespaces:
Zend_Session::destroy();
To remove one specific Space name:
Zend_Session::namespaceUnset('default');
possibly with
$bootstrap = $this->getInvokeArg('bootstrap'); $cache = $bootstrap->getResource('cache'); $cache->clean(Zend_Cache::CLEANING_MODE_ALL);
Source: https://habr.com/ru/post/894612/More articles:Serializing EF4.1 Objects Using JSON.Net - serializationHow to resolve AVCaptureSession v AVAudioSession conflict in iOS? - iosHow to set custom repeat interval for Nslocal notification .....? - objective-cUsing Knockout.js with CouchDB - Update on Change - couchdbJquery ui widget extension - how to access parent event - javascriptVisual Studio Development Server (2010) and NTLM authorization - authenticationHow to concatenate a string and GETDATE () in MSSQL - stringIs there an alternative to switching in a factory method? - design-patternsIs there a way to provide self-service online advertising based on Mercurial repositories such as BitBucket / Kiln? - cloneHow to deserialize from a file to another class - javaAll Articles