I want to put some stuff into the cache inside an action.
I tried:
- Code: Select all
$cacheManager = sfContext::getInstance()->getViewCacheManager();
$cacheManager->set('something');
or
- Code: Select all
$this->getContext()->getViewCacheManager()->set('something');
But with both situations I get "Fatal error: Call to a member function set() on a non-object in ...."
If I read the documentation I guess the above code is correct, or can somebody tell me what I do wrong?
Thnx!!
Pieter
