PHP在win2000下的配置问题

黑夜路人
博客专家认证
2004-03-20 09:25:23
在2000超级服务器版下配置的,配置没有错误,并且把php.ini已经复制到了c:\winnt
目录下了,但是在调试中出现下面的错误:

Security Alert! The PHP CGI cannot be accessed directly.
This PHP CGI binary was compiled with force-cgi-redirect enabled. This means that a page will only be served up if the REDIRECT_STATUS CGI variable is set, e.g. via an Apache Action directive.

For more information as to why this behaviour exists, see the manual page for CGI security.

For more information about changing this behaviour or re-enabling this webserver, consult the installation file that came with this distribution, or visit the manual page.


不知道原因是什么,请高手指点!
...全文
76 10 打赏 收藏 转发到动态 举报
写回复
用AI写文章
10 条回复
切换为时间正序
请发表友善的回复…
发表回复
johnpanq 2004-03-20
  • 打赏
  • 举报
回复
修改php.ini中的
cgi.force_redirect = 1 为
cgi.force_redirect = 0 即可。
设为1时,cgi不能在IIS下使用,在php4.1.2以后,都默认为1,所以要改成0.
xylegend 2004-03-20
  • 打赏
  • 举报
回复
PHP重新安装试试
黑夜路人 2004-03-20
  • 打赏
  • 举报
回复
C盘是NTFS分区
是不是因为权限设置,导致iusr_xxx用户无法读取php.ini文件?
pangyunqing 2004-03-20
  • 打赏
  • 举报
回复
你得php.ini安装目录是不是在ntfs的格式的硬盘下,如果是就必须将php安装目录下的可执行权限指定给IUR_什么的用户。
黑夜路人 2004-03-20
  • 打赏
  • 举报
回复
用的是IIS,配置应该没问题,是按照别的已经成功的例子配置的.
同时php.ini也应该没有问题,因为是从别的正常运行的php.ini拷过来的. :(
weq221 2004-03-20
  • 打赏
  • 举报
回复
你用iis还是apache?
52juanjuan 2004-03-20
  • 打赏
  • 举报
回复
你用<?phpinfo()?>是什么东西呀,看有没有PHP CGI 方面的东西
ice_berg16 2004-03-20
  • 打赏
  • 举报
回复
这句前面的分号有没有去掉?
确认去掉并且重启服务器
黑夜路人 2004-03-20
  • 打赏
  • 举报
回复
我的PHP的选项是:
cgi.force_redirect = 0
不知道为什么???
IvanQi 2004-03-20
  • 打赏
  • 举报
回复
同意johnpanq(飞花逐月)

21,886

社区成员

发帖
与我相关
我的任务
社区描述
从PHP安装配置,PHP入门,PHP基础到PHP应用
社区管理员
  • 基础编程社区
加入社区
  • 近7日
  • 近30日
  • 至今
社区公告
暂无公告

试试用AI创作助手写篇文章吧