当前位置:首页 > 服务器技术 > nginx

nginx下fastcgi_param运行php出现空白页的问题

  1. fastcgi_param SCRIPT_FILENAME /home/www/scripts/php$fastcgi_script_name;
  2. fastcgi_param QUERY_STRING $query_string;

Parameter SCRIPT_FILENAME is used by PHP for determining the name of script to execute, and QUERY_STRING contains the parameters of the request.

所以,在没有定义SCRIPT_FILENAME这个系统变量时,php是没法解释执行的。

此变量的定义可以写在nginx的配置文件nginx.conf里,也可以写在外部文件,然后用include的方式在nginx.conf里包含进来。 您可能感兴趣的文章: nginx+php-fpm页面显示空白的解决方法 有关nginx+php-fpm配置文件的组织结构 nginx下跑php的程序,返回200,但是空白页


【说明】本文章由站长整理发布,文章内容不代表本站观点,如文中有侵权行为,请与本站客服联系(QQ:254677821)!