为什么我的apache个人目录中无法解析php文件?

由 escapedd 在 12-26-2003 13:34 发表:

为什么我的apache个人目录中无法解析php文件?

整了一个晚上还没搞定,郁闷……

1、服务器本来可以正常解析php文件,php已经安装为apache的dso

2、我的个人目录是/home/www/public_html

3、通过 http://localhost/~www/来执行cgi文件一切正常

4、如果php文件的属性不改为777的话,就会提示没有权限访问这个文件,

如果改为777,则提示“Internal Server Error”

5、apache日志中有如下记录:

[Web Dec 24 10:22:08 2003] [error] (8)Exec format error: exec of /home/www/public_html/index.php failed

[Web Dec 24 10:22:08 2003] [error] [client 192.168.0.1] Premature end of script headers: /home/www/pulic_html/index.php

6、apache中关于用户目录设置如下:

 1<directory *="" home="" public_html="">   
 2  
 3Options MultiViews Indexes SymLinksIfOwnerMatch IncludesNoExec ExecCGI   
 4  
 5SetHandler cgi-script   
 6  
 7DirectoryIndex index.php   
 8  
 9AllowOverride None   
10  
11Or</directory>
Published At
Categories with 服务器类
Tagged with
comments powered by Disqus