示例#1
0
 public function __construct()
 {
     parent::__construct();
     $redisHost = Configure::get('redis', 'host');
     $redisPort = Configure::get('redis', 'port');
     $this->connect($redisHost, $redisPort);
 }
示例#2
0
文件: test.php 项目: im286er/LuckyPHP
 protected function redis()
 {
     $redis = new Redis();
     $redis->set('cache', 'test', 10);
     echo $redis->get('cache');
 }