Access denied (403) for PHP files with Nginx + PHP-FPM

后端 未结 7 1692
孤街浪徒
孤街浪徒 2020-12-13 04:58

I have been spending few hours on that issue and despite the high number of posts related to it, I cannot solve it. I have a Fedora 20 box with Nginx + PHP-FPM that worked q

7条回答
  •  猫巷女王i
    2020-12-13 05:05

    This could also happen if there is no index.php in your vhost document root.

    Carefully double-check the www_root parameter in your nginx configuration. Then double check that the php file you're trying to hit is actually in there.

    In my case, I mis-typed the vhost doc root path and so pointed it to an empty directory, yielding a 403.

提交回复
热议问题