windows PHP上传文件使用Windows IIS服务器继承权限错误
声明:本页面是StackOverFlow热门问题的中英对照翻译,遵循CC BY-SA 4.0协议,如果您需要使用它,必须同样遵循CC BY-SA许可,注明原文地址和作者信息,同时你必须将它归于原作者(不是我):StackOverFlow
原文地址: http://stackoverflow.com/questions/12786191/
Warning: these are provided under cc-by-sa 4.0 license. You are free to use/share it, But you must attribute it to the original authors (not me):
StackOverFlow
PHP upload file inherit permissions error using Windows IIS Server
提问by peter n
My colleague has been uploading files via PHP hosted on Windows Server 2008 IIS 7, but she's been having a problem downloading them, even though proper permissions on the upload folder are granted to the IIS_USRS group. Turns out the uploaded files aren't!
我的同事一直在通过托管在 Windows Server 2008 IIS 7 上的 PHP 上传文件,但她在下载文件时遇到了问题,即使已将上传文件夹的适当权限授予 IIS_USRS 组。原来上传的文件不是!
回答by peter n
In the hope that this might help someone else, I researched and found a solution here:
希望这可以帮助其他人,我在这里研究并找到了解决方案:
http://www.howyoudo.info/index.php/how-to-fix-windows-server-upload-file-inherit-permissions-error/
http://www.howyoudo.info/index.php/how-to-fix-windows-server-upload-file-inherit-permissions-error/
In short, change the permissions on "upload_tmp_dir" (path in php.ini file) folder to match your web app folder permissions.
简而言之,更改“upload_tmp_dir”(php.ini 文件中的路径)文件夹的权限以匹配您的 Web 应用程序文件夹权限。
If you cannot or do not want to change the permissions on the temp folder (the system temp folder by default). Then create a new temp folder and set the desired permission on that. Then update the PHP INI upload_tmp_dir value to point to that directory.
如果您不能或不想更改临时文件夹(默认为系统临时文件夹)的权限。然后创建一个新的临时文件夹并设置所需的权限。然后更新 PHP INI upload_tmp_dir 值以指向该目录。

