thinkphp6 缓存
2022-07-28 14:14:58
121
{{single.collect_count}}

系统内置了很多类型的缓存,除了 File,其它均需要结合相关产品;

这里主要演示 File 文本缓存,“其它的需要学习相关产品”;

配置文件 cache.php 进行缓存配置,默认生成在 runtime/cache 目录;

<?php//助手函数的使用:cache();cache('user', 'Mr.Lee', 3600);//设置缓存echo cache('user'
回帖
全部回帖({{commentCount}})
{{item.user.nickname}} {{item.user.group_title}} {{item.friend_time}}
{{item.content}}
{{item.comment_content_show ? '取消' : '回复'}} 删除
回帖
{{reply.user.nickname}} {{reply.user.group_title}} {{reply.friend_time}}
{{reply.content}}
{{reply.comment_content_show ? '取消' : '回复'}} 删除
回帖
收起
没有更多啦~
{{commentLoading ? '加载中...' : '查看更多评论'}}