Cannot Save File to directory using FPDF

不羁的心 提交于 2019-12-04 15:57:23

If your PHP script is executed from a web-page (served by Apache, it is), then this code will be executed by the Apache (sometimes called www-data) user.

So, your Apache user needs to be able to write to the directory you're trying to write to.


Typically, you might have to give the write privilege to the other users of your system, using something like this from a command-line :

chmod o+w your_directory


The software you're using to upload your source files, if doing so using a GUI, should allow you to do that with a couple of chekboxes -- you need to check the "write" checkbox for the "others" users.

Robert Saylor

chmod o+w your_directory fixed it for me :)

标签
易学教程内所有资源均来自网络或用户发布的内容,如有违反法律规定的内容欢迎反馈
该文章没有解决你所遇到的问题?点击提问,说说你的问题,让更多的人一起探讨吧!