Nav apraksta
Nevar pievienot vairāk kā 25 tēmas Tēmai ir jāsākas ar burtu vai ciparu, tā var saturēt domu zīmes ('-') un var būt līdz 35 simboliem gara.

12345678910111213141516171819202122232425262728293031323334353637383940414243444546474849
  1. <?php
  2. // +----------------------------------------------------------------------
  3. // | ThinkPHP [ WE CAN DO IT JUST THINK ]
  4. // +----------------------------------------------------------------------
  5. // | Copyright (c) 2006~2018 http://thinkphp.cn All rights reserved.
  6. // +----------------------------------------------------------------------
  7. // | Licensed ( http://www.apache.org/licenses/LICENSE-2.0 )
  8. // +----------------------------------------------------------------------
  9. // | Author: liu21st <liu21st@gmail.com>
  10. // +----------------------------------------------------------------------
  11. // +----------------------------------------------------------------------
  12. // | 缓存设置
  13. // +----------------------------------------------------------------------
  14. return [
  15. // 复合缓存类型
  16. 'type' => 'complex',
  17. // 默认使用的缓存
  18. 'default' => [
  19. 'type' => 'file', // 驱动方式
  20. 'path' => '', // 缓存保存目录
  21. 'prefix' => '', // 缓存前缀
  22. 'expire' => 0, // 缓存有效期 0表示永久缓存
  23. ],
  24. // 文件缓存
  25. 'file' => [
  26. 'type' => 'file',
  27. 'expire' => 0,
  28. 'prefix' => '',
  29. ],
  30. // redis缓存
  31. 'redis' => [
  32. 'type' => 'redis',
  33. 'host' => '127.0.0.1',
  34. 'port' => 6379,
  35. 'password' => '',
  36. 'expire' => 0,
  37. 'prefix' => '',
  38. ],
  39. //memcache缓存,或memcached更高级
  40. 'memcache' => [
  41. 'type' => 'memcache',
  42. 'host' => '127.0.0.1',
  43. 'port' => 11211,
  44. 'expire' => 0,
  45. 'prefix' => '',
  46. ],
  47. ];