PHP关闭php.ini中的警告不起作用

时间:2014-06-21 06:48:05

标签: php linux directadmin

我有一个带有root访问权限的Linux CentOS和DirectAdmin控制面板的VPS。 我已经恢复了一个网站,它显示了一些警告:

Warning: file_put_contents(/home/site/domains/mysite.com/public_html/news/art/wp-content/themes/aggregator/cache//6d6888104966bb46e070bdf21b1efd2c.spc) [function.file-put-contents]: failed to open stream: Permission denied in /home/site/domains/mysite.com/public_html/news/art/wp-content/themes/aggregator/php/simplepie.inc on line 8670

所以我试图通过编辑php.ini文件来关闭所有警告:

error_reporting = E_ALL & ~E_WARNING

我重新启动了系统。但它不起作用。我也意识到我的系统上有两个php.ini文件:

/usr/local/etc/php5/cgi/php.ini

/usr/local/lib/php.ini

我不知道该怎么做。有什么帮助吗?!

由于

1 个答案:

答案 0 :(得分:0)

尝试删除

/home/site/domains/mysite.com/public_html/news/art/wp-content/themes/aggregator/cache/

文件夹。确保您具有在缓存文件夹中写入的正确权限。不要与警告作斗争 - 修复权限问题。