Home >Backend Development >PHP Tutorial >访问apache里的资源直接下载其文件

访问apache里的资源直接下载其文件

WBOYWBOYWBOYWBOYWBOYWBOYWBOYWBOYWBOYWBOYWBOYWBOYWB
WBOYWBOYWBOYWBOYWBOYWBOYWBOYWBOYWBOYWBOYWBOYWBOYWBOriginal
2016-06-23 14:40:161724browse

访问php文件会提示下载其文件,什么原因?http.conf关于php的配置如下:

AddType application/x-httpd-php .php
AddType application/x-httpd-php .html
AddType application/x-httpd-php .htm

LoadModule php5_module "D:/php/php5apache2_2.dll"
PHPIniDir "D:/php/php.ini"


回复讨论(解决方案)

检查D:/php下是不是存在php5apache2_2.dll文件?

PHPIniDir "D:/php/php.ini"
改成
PHPIniDir "D:/php/"

检查D:/php下是不是存在php5apache2_2.dll文件?

PHPIniDir "D:/php/php.ini"
改成
PHPIniDir "D:/php/"

果然是PHPIniDir的问题,谢谢

Statement:
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
Previous article:php.ini文件?Next article:多表搜索问题