当前位置:Gxlcms > PHP教程 > nginx下fastcgi_param运行php出现空白页的问题

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

时间:2021-07-01 10:21:17 帮助过:4人阅读

  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,但是空白页

人气教程排行