如果我去我的网站http://www.website.com (在一个全新的服务器)的主页index.php获取donwloaded而不是处理。 我没有在其他文件夹相同的问题。 我的.htaccess显示:
AddHandler php5-script .php
这可能是什么? 我怀疑这是与PHPconfiguration/或htaccess的东西,但我无法弄清楚。 请帮助!
编辑:我不知道这是否有帮助:这是一个wordpress安装,我有这个问题只在网站的公共部分,而不是在pipe理员(即正确呈现)
我相信你的处理程序是错误的。 根据http://wiki.apache.org/httpd/PHPDownload你需要使用:
# (other modules) # Replace the following with the correct path and version of your php module LoadModule php5_module modules/libphp5.so # (other modules) <FilesMatch \.php$> SetHandler application/x-httpd-php </FilesMatch>
尝试一个简单的脚本,看看它是否工作。 index.php可能有问题。
in test.php: <?php echo phpinfo(); ?>