nginx搭建的服务器 报No input file specified错我把php-fpm重启下就能访问了 然后没过多久又抱No input file specified错php-fpm在重启下又可以正常访问了 请问各位大神这是什么原因啊 要怎么解决呢以下是server配置server { listen 80; server_name _; root /home/wwwroot/appcation/web; index index.php index.html; access_log logs/app_access.log; error_log logs/app_error.log; #include enable-php.conf; location / { if (!-e $request_filename){ rewrite ^/(.*) /index.php last; } } location ~ .php$ { root /home/wwwroot/appcation/web; fastcgi_pass unix:/tmp/php-cgi.sock; fastcgi_index index.php; fastcgi_param SCRIPT_FILENAME $document_root$fastcgi_script_name; include fastcgi_params; } }
3 回答
已采纳
灬紫羽
TA贡献107条经验 获得超71个赞
您的服务器不支持 PATH_INFO;
在php.ini文件里面修改:
1、增加一行(这个最重要)
fastcgi.impersonate = 1
2、修改两项(解开注释就可以了)
cgi.fix_pathinfo=1
cgi.force_redirect = 0
- 3 回答
- 0 关注
- 2305 浏览
添加回答
举报
0/150
提交
取消
