欢迎各位兄弟 发布技术文章

这里的技术是共享的

You are here

drupal第三方缓存模块 cacherouter

shiping1 的头像

drupal第三方缓存模块 不指定

drupal水滴 , 2012/03/05 11:59 , drupal建站 » drupal模块 , 评论(0) , 阅读(800) | |
   第3方模块cacherouter (http://drupal.org/project/cacherouter)就是一个利用fastpath模式的模块。假定你把这个模块安装在了sites/all/modules/contrib中。
    由于fastpath在默认情况下不会创建数据库连接,所以要将所有的配置选项放在你的settings.php文件中:

$conf = array(
    'page_cache_fastpath' => TRUE,
    'cache_inc' => './sites/all/modules/contrib/cacherouter/cacherouter.inc',
    ... // More settings here.
);

    数 组中的第一项,通过将page_cache_fastpath设置为TRUE来启用fastpath模式。这样就启用了fastpath模式,非常简单! 第2项用来声明Drupal将要加载的文件,将会使用这个文件来代替includes/cache.inc。在这种情况下,声明的文件就是 cacherouter模块将要使用的自定义缓存库。cacherouter模块还需要更多一点的配置;详细可参看http://drupal.org /project/cacherouter。

    如果你要加载自己的自定义缓存库,来代替Drupal默认使用的includes/cache.inc库,那么你需要编写你自己的cache_set(),cache_get()和cache_clear_all()函数。

注意 一旦启用了fastpath缓存,那么它将覆写在Drupal管理界面中设置的任意缓存选项。 相关日志
网站ip限制访问模块
表单添加other的字段
价格属性模块
userpoints_retroactive升级到d7
页边添加广告效果模块curlypage

来自 http://www.majormoves.net/post/1051/
普通分类: