fastcgi +php 提示 No input file specified.怎么解决

WBOY
Release: 2016-06-23 13:38:37
Original
924 people have browsed it

服务器上有别的php 可以运行, 新建的就是不行, 


回复讨论(解决方案)

日志中应该有更多的信息,估计是你新建的文件权限不对,导致进程无法访问此文件

目录权限的问题。

你用了htaccess吧?

<IfModule mod_rewrite.c>   RewriteEngine on   RewriteCond %{REQUEST_FILENAME} !-d   RewriteCond %{REQUEST_FILENAME} !-f   RewriteRule ^(.*)$ index.php?/$1 [QSA,PT,L]</IfModule>
Copy after login
Copy after login


你用了htaccess吧?

<IfModule mod_rewrite.c>   RewriteEngine on   RewriteCond %{REQUEST_FILENAME} !-d   RewriteCond %{REQUEST_FILENAME} !-f   RewriteRule ^(.*)$ index.php?/$1 [QSA,PT,L]</IfModule>
Copy after login
Copy after login


就没有这个文件,而且我 也试过,就算有这个, 也不会出现404,  thinkphp 前段时间研究过, 看到就算这段代码,
我的是iis 所以 htaccess 无效

楼上的都不行啊,
只有php文件不能访问, 其他的如: html,jpg,gif,等都可以正常查看

日志 访问路径和看到的是一样的, 没有 htaccess,和httpd.ini 文件

找到解决办法了


打开php.ini文件,这个你看你怎么配置的了。

在php.ini文件里面修改:

1、增加一行(这个最重要)

fastcgi.impersonate = 1       // 我解除了这个注释就行了, 下面2个已经设置好了

2、修改两项(解开注释就可以了)

cgi.fix_pathinfo=1
cgi.force_redirect = 0


source:php.cn
Statement of this Website
The content of this article is voluntarily contributed by netizens, and the copyright belongs to the original author. This site does not assume corresponding legal responsibility. If you find any content suspected of plagiarism or infringement, please contact admin@php.cn
Popular Tutorials
More>
Latest Downloads
More>
Web Effects
Website Source Code
Website Materials
Front End Template
About us Disclaimer Sitemap
php.cn:Public welfare online PHP training,Help PHP learners grow quickly!