欢迎您访问程序员文章站本站旨在为大家提供分享程序员计算机编程知识!
您现在的位置是: 首页  >  后端开发

php文件打开显示空白

程序员文章站 2022-05-20 22:58:51
...
查看nginx的日志错误信息如下:2016/03/22 18:59:40 [error] 20273#0: *11 FastCGI sent in stderr: "PHP message: PHP Warning: require_once(/home/dwj/phpblog/inc/../vendor/autoload.php): failed to open stream: No such file or directory in /home/dwj/phpblog/inc/blade.php on line 3
PHP message: PHP Fatal error: require_once(): Failed opening required '/home/dwj/phpblog/inc/../vendor/autoload.php' (include_path='.:/usr/share/php:/usr/share/pear') in /home/dwj/phpblog/inc/blade.php on line 3" while reading response header from upstream, client: 218.75.123.165, server: dwjdwj.cn, request: "GET /index.php HTTP/1.1", upstream: "fastcgi://unix:/var/run/php5-fpm.sock:", host: "dwjdwj.cn"

个人感觉好像是路径问题,但是不知道该怎么改。求解答

回复内容:

查看nginx的日志错误信息如下:2016/03/22 18:59:40 [error] 20273#0: *11 FastCGI sent in stderr: "PHP message: PHP Warning: require_once(/home/dwj/phpblog/inc/../vendor/autoload.php): failed to open stream: No such file or directory in /home/dwj/phpblog/inc/blade.php on line 3
PHP message: PHP Fatal error: require_once(): Failed opening required '/home/dwj/phpblog/inc/../vendor/autoload.php' (include_path='.:/usr/share/php:/usr/share/pear') in /home/dwj/phpblog/inc/blade.php on line 3" while reading response header from upstream, client: 218.75.123.165, server: dwjdwj.cn, request: "GET /index.php HTTP/1.1", upstream: "fastcgi://unix:/var/run/php5-fpm.sock:", host: "dwjdwj.cn"

个人感觉好像是路径问题,但是不知道该怎么改。求解答

用 function __autoload($class)

意思就是/home/dwj/phpblog/vendor/autoload.php这个文件不存在,你可能写错路径了。
另外,在php.ini中把错误提示打开,开发模式下屏蔽错误信息就是给自己找麻烦。

相关标签: php