久久青草精品A片狠狠,日韩欧美视频一区二区,亚洲国码AV日韩,国产精品黄在

幫助中心 >  技術(shù)知識(shí)庫(kù) >  云服務(wù)器 >  服務(wù)器教程 >  Apache下“Cannot load php5apache2_4.dll into server”問(wèn)題的解決方法

Apache下“Cannot load php5apache2_4.dll into server”問(wèn)題的解決方法

2016-10-25 08:21:21 21738

下載了最新的PHP+Apache Httpd Server,版本號(hào)分別為5.5.0和2.4.3,完成配置修改后,啟動(dòng)Apache服務(wù)器,上報(bào)“Cannot load php5apache2_4.dll into server”錯(cuò)誤。

1、以為是配置文件寫錯(cuò),仔細(xì)檢查后,確實(shí)沒(méi)有看出什么問(wèn)題。

2、以為是采用了不匹配的線程安全版本,仔細(xì)檢查后,PHP和Apache均是線程安全的版本。

3、排除法,刪除httpd.conf中的這句話,Apache啟動(dòng)成功。Windows上的PHP和Apache采用dll動(dòng)?鏈接庫(kù)的方式配合,一種CGI方式,感覺(jué)問(wèn)題出在dll上。

LoadModule php5_module "D:PHPphp5apache2_4.dll"

4、查找網(wǎng)上的一些帖子,各種分析較多,搞得我思路混亂。但我堅(jiān)信問(wèn)題一定不會(huì)是PHP和Apache兩個(gè)組織?有相互測(cè)試配套關(guān)系,肯定是自己哪里理解錯(cuò)了,決定登錄PHP官網(wǎng),windows.php.net,找到下面一段話,人家說(shuō)的很清楚:

Which version do I choose?

IISIf you are using PHP with IIS you should use the Non-Thread Safe (NTS) versions of PHP.

Apache
Please use the Apache builds provided by Apache Lounge. They also provide VC11 builds of Apache for x86 and x64. We use their binaries to build the Apache SAPIs.If you are using PHP with Apache 1 or Apache2 from apache.org (not recommended) you need to use the older VC6 versions of PHP compiled with the legacy Visual Studio 6 compiler. Do NOT use VC9+ versions of PHP with the apache.org binaries.

VC9 and VC11
More recent versions of PHP are built with VC9 or VC11 (Visual Studio 2008 and 2012 compiler respectively) and include improvements in performance and stability.

The VC9 builds require you to have the Visual C++ Redistributable for Visual Studio 2008 SP1 x86 or x64 installed.

查看系統(tǒng)的Visual Studio Distribute版本是2008,對(duì)應(yīng)VC9,但我使用的是Visual Studio 2012編譯的PHP版本(VC11),動(dòng)態(tài)連接于Apache中的dll,可能就會(huì)出現(xiàn)問(wèn)題。重新下載了VC9版本的PHP,Apache Httpd Server啟動(dòng)成功,問(wèn)題解決!


提交成功!非常感謝您的反饋,我們會(huì)繼續(xù)努力做到更好!

這條文檔是否有幫助解決問(wèn)題?

非常抱歉未能幫助到您。為了給您提供更好的服務(wù),我們很需要您進(jìn)一步的反饋信息:

在文檔使用中是否遇到以下問(wèn)題: