「Cannot load php 5 apache 2_4.dll into server」問題の解決方法

1829 ワード

最新のPHP+Apache Httpd Serverをダウンロードしました.バージョン番号はそれぞれ5.5です.0と2.4.3、構成変更が完了したら、Apacheサーバを起動し、「Cannot load php 5 apache 2_4.dll into server」エラーを報告します.
1、コンフィギュレーションファイルが間違っていると思って、よくチェックしてみると、確かに何の問題も見えませんでした.
2、一致しないスレッドセキュリティバージョンを採用したと思って、よくチェックした後、PHPとApacheはいずれもスレッドセキュリティバージョンである.
3、排除法、httpdを削除する.confのこの言葉で、Apacheの起動に成功しました.Windows上のPHPとApacheはdllダイナミックリンクライブラリを採用しており、CGI方式であり、dllに問題があると感じている.
LoadModule php5_module "D:\PHP\php5apache2_4.dll"

4、ネット上のいくつかの投稿を探して、いろいろな分析が多くて、私の考えを混乱させました.しかし、私は問題がPHPとApacheの2つの組織が互いに関連関係をテストしていないことはないと信じています.自分のどこか理解が間違っているに違いありません.PHP公式サイトに登録することにしました.windows.php.Net、次の言葉を見つけて、人の言うことははっきりしています.
Which version do I choose?

IIS
If 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.

表示システムのVisual Studio Distributeバージョンは2008でVC 9対応ですが、Visual Studio 2012でコンパイルされたPHPバージョン(VC 11)を使用しています.Apacheのdllに動的に接続すると、問題が発生する可能性があります.VC 9バージョンのPHPを再ダウンロードし、Apache Httpd Serverが起動し、問題解決!
オープンソースソフトウェアをダウンロードするときは、コンパイル環境のバージョンに特に注意し、ソフトウェアのバージョンReleaseNotesをよく読むと、ほとんどの問題を解決することができます.