# chmod -R 777 /var/www/html
加入-R 参数,就可以将读写权限传递给子文件夹。
那么html文件夹和它下面的所有子文件夹的属性都变成了777(777是读、写、执行权限)。
这样php的file_put_contents 函数在执行过程中就不会报错了。(failed to open stream: Permission denied)
# chmod -R 777 /var/www/html
加入-R 参数,就可以将读写权限传递给子文件夹。
那么html文件夹和它下面的所有子文件夹的属性都变成了777(777是读、写、执行权限)。
这样php的file_put_contents 函数在执行过程中就不会报错了。(failed to open stream: Permission denied)