thinkphp的Runtime出现缓存写入失败

WBOY
Release: 2016-06-06 20:43:44
Original
1450 people have browsed it

我知道可以通过更改权限来解除,但我的文件在别人的服务器,无法修改权限,只能修改代码。有没其它方法可以解决问题,比如不要缓存写入行不行,怎么做

回复内容:

我知道可以通过更改权限来解除,但我的文件在别人的服务器,无法修改权限,只能修改代码。有没其它方法可以解决问题,比如不要缓存写入行不行,怎么做

肯定是权限问题了!chmod -R 777
把Runtime文件权限给了!
顺便看看用户和分组
chown -R GROUP:USER Runtime

这个是部署的系统有关系,具体给的越详细我们越好给出!

其实TP是有这个选项的。
当你开启了调试模式,就不会有缓存了,每次都是重新编译。

<code>'TMPL_CACHE_ON' => true, // 是否开启模板编译缓存,设为false则每次都
会重新编译</code>
Copy after login

配置文件中说明就好。
还有cache缓存,不要用文件类型的,用第三方的memcahche啥的。

Related labels:
source:php.cn
Statement of this Website
The content of this article is voluntarily contributed by netizens, and the copyright belongs to the original author. This site does not assume corresponding legal responsibility. If you find any content suspected of plagiarism or infringement, please contact admin@php.cn
Popular Tutorials
More>
Latest Downloads
More>
Web Effects
Website Source Code
Website Materials
Front End Template
About us Disclaimer Sitemap
php.cn:Public welfare online PHP training,Help PHP learners grow quickly!