//调用cache,参数'com_campaign'为缓存组,必须!$cache= jfactory::getcache('com_campaign','');//设置:即使关闭全局缓存时,此缓存仍有效$cache->setcaching(true);//设置缓存时间,此处设置为 60s$cache->setlifetime(60);//获取缓存$name=$cache->get('userid_101');if(!$name){ $str='my name is cache'; //设置缓存$cache->store($str,'userid_101');}echo ''
;print_r($name);exit;//移除缓存$cache->remove('userid_101');//获取全部缓存对象列表及简介$cache->getall();//清除缓存组。第二个参数为:group|notgroup 默认为group。notgroup不知道是干什么的$cache->clean('com_campaign','group');参考地址:
https://api.joomla.org/cms-3/classes/jcache.html
https://docs.joomla.org/api15:jcache
').addclass('pre-numbering').hide(); $(this).addclass('has-numbering').parent().append($numbering); for (i = 1; i ').text(i)); }; $numbering.fadein(1700); }); }); 以上就介绍了 joomla 缓存 jcache,包括了方面的内容,希望对php教程有兴趣的朋友有所帮助。
