thinkphp 结合memcache 使用

1. 下载php_memcache.dll;

2.放到php/ext 文件夹下面;

3.php.ini 增加extension=php_memcache.dll 

4.修改thinkphp config.php 配置文件:   'DATA_CACHE_TYPE' => 'Memcache', 'DATA_CACHE_TIME' => '3600',

5.thinkphp 实现代码:

eg: 

     function index(){
S('test','goirl');
$test = S('test');
 echo $test;

    }




发布了19 篇原创文章 · 获赞 5 · 访问量 2万+

猜你喜欢

转载自blog.csdn.net/u011151452/article/details/51840259