在apache的httpd.conf文件最后处添加了以下内容
ScriptAlias   /php5.2/   "D:/BugManageTool/php5.2/"
AddType   application/x-httpd-php   .php3 
AddType   application/x-httpd-php   .php 
AddType   application/x-httpd-php   .phtml 
Action   application/x-httpd-php   "/php5.2/php.exe"
然后127.0.0.1出错
Internal Server Error
The server encountered an internal error or misconfiguration and was unable to complete your request.Please contact the server administrator, [email protected] and inform them of the time the error occurred, and anything you might have done that may have caused the error.More information about this error may be available in the server error log.
查看error.log后看到
[Sat Aug 21 11:02:10 2010] [error] [client 127.0.0.1] Premature end of script headers: php.exe
请问是什么原因,急,在线等。

解决方案 »

  1.   

    这个不对
    Action application/x-httpd-php "/php5.2/php.exe"httpd.conf中配置应该是这样

    LoadModule php5_module "c:/php/php5apache2.dll" #改成你自己的目录
    AddHandler application/x-httpd-php .php# configure the path to php.ini
    PHPIniDir "C:/php" #改成你自己的目录重启Apache
      

  2.   

      AddType application/x-httpd-php .php
        AddType application/x-httpd-php .html
        AddType application/x-httpd-php .php .phtml .php3 .php4
    AddType application/x-httpd-php-source .phps
      

  3.   


    改成这个之后apache重启都不行