[英]WordPress files permissions on Apache
What is the best approach with files permissions for WordPress site on Apache? Apache 上 WordPress 站点的文件权限的最佳方法是什么? I'd like to be able to upload plugins directly to my local server.我希望能够将插件直接上传到我的本地服务器。 I'm able to do that if I change ownership on my WordPress instance files to _www
.如果我将 WordPress 实例文件的所有权更改为_www
,我就可以做到这_www
。 On the other hand, this makes OS X asking for password each time I'm saving any of those files.另一方面,这使得 OS X 每次保存这些文件时都要求输入密码。 I want to save them without typing password.我想在不输入密码的情况下保存它们。
What can I do to satisfy both needs?我能做些什么来满足这两种需求?
What I do is: make sure the user is all over wordpress files as owner ang group.我所做的是:确保用户以所有者 ang 组的身份在 wordpress 文件中。 The commands are:命令是:
chown user:user -R *
Then permissions are these:然后权限是这些:
sudo find . -type f -exec chmod 664 {} +
sudo find . -type d -exec chmod 775 {} +
sudo chmod 660 wp-config.php
You can also add these permissions to uploads folder:您还可以将这些权限添加到上传文件夹:
chmod 755 -R uploads
And you should be ready to go.你应该准备好了。
声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.