开发者

how do i use zfdebug cache plugin?

i'm using latest svn version (1.6) of zfdebug with zend 1.11.4 and trying to get zfdebug's cache plugin to work

i found these 2 examples: http://code.google.com/p/zfdebug/wiki/Installation and http://www.jaceju.net/blog/archives/1077,

in my bootstrap.php the code

# Setup the cache plugin
if ($this->hasPluginResource('cache')) {
    $this->bootstrap('cache');
    $cache = $this->getPluginResource('cache')->getDbAdapter();
    $op开发者_StackOverflow中文版tions['plugins']['Cache']['backend'] = $cache->getBackend();
}

doesn't seem to work, i get Call to undefined method Gestionale_Application_Resource_Cache::getDbAdapter()

my application.ini has this

;cache stuff
resources.cache.frontEnd = core 
resources.cache.backEnd = file 
resources.cache.frontEndOptions.lifetime = 1200 ; in secondi
resources.cache.frontEndOptions.automatic_serialization = true 
resources.cache.backEndOptions.lifetime = 3600 ; in secondi
resources.cache.backEndOptions.cache_dir = APPLICATION_PATH "/../cache"
pluginPaths.Gestionale_Application_Resource = APPLICATION_PATH "/../library/Gestionale/Application/Resource"  
;;fine cache stuff

thanks :)


replace


# Setup the cache plugin
if ($this->hasPluginResource('cache')) {
    $this->bootstrap('cache');
    $cache = $this->getPluginResource('cache')->getDbAdapter();
    $options['plugins']['Cache']['backend'] = $cache->getBackend();
}

by


# Setup the cache plugin
if ($this->hasResource('cache')) {
  $this->bootstrap('cache');
  $options['plugins']['Cache']['backend'] = $this->getResource('cache')->getBackend();
}
0

上一篇:

下一篇:

精彩评论

暂无评论...
验证码 换一张
取 消

最新问答

问答排行榜