Package Data | |
---|---|
Maintainer Username: | hacklee |
Maintainer Contact: | 517184100@qq.com (liguoyi) |
Package Create Date: | 2015-08-13 |
Package Last Update: | 2016-01-08 |
Language: | PHP |
License: | MIT |
Last Refreshed: | 2024-11-19 03:05:20 |
Package Statistics | |
---|---|
Total Downloads: | 721 |
Monthly Downloads: | 2 |
Daily Downloads: | 0 |
Total Stars: | 3 |
Total Watchers: | 1 |
Total Forks: | 1 |
Total Open Issues: | 0 |
在laravel中用外观模式操作php的redis扩展类
pecl install redis
phpredis扩展的github地址:https://github.com/phpredis/phpredis
'redis' => [
'default' => [
'host' => '127.0.0.1',
'port' => 6379,
'password' => '',
'database' => 0,
],
]
composer require hacklee/laravel5-php-redis
或修改composer.json,在require加上 "hacklee/laravel5-php-redis": "dev-master" 然后执行composer update
Hacklee\PRedisServiceProvider::class
或
'Hacklee\PRedisServiceProvider'
'PRedis' => Hacklee\PRedisFacade::class
或
'PRedis' => 'Hacklee\PRedisFacade'
$val = \PRedis::get('key');
use PRedis;
$val = PRedis::get('key');
redis扩展的更多操作,请参考官网文档phpredis