文件目录写下报错

WBOY
Release: 2016-06-13 12:40:01
Original
916 people have browsed it

文件目录写入报错
我用php建立一个文件夹。设置0777权限。用file_put_content写入文件报错:
failed to open stream: Permission denied'

1、首先想到的就是权限问题,我用函数判断创建的文件夹是否有可写权限。我创建test.txt测试,可以成功。
还有奇怪的是,程序往里面写入十几个文件都成功,但写到某个文件就报错了。如果没有可写权限,应该是一个文件都没有创建成功才是呀。

2、路径是正确的,这点检查很多遍了。

此外我想不到其他可能性了。麻烦高手指点一下,谢谢。

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