Click to See Complete Forum and Search --> : PHP problem with php4apache.dll


Anon
07-02-2002, 07:05 PM
I was wondering if anyone has encountered this problem.. I am new to the whole apache for windows scene. Anyway, I've managed to succesfully install Apache/2.0.39 under Windows XP on my HP OmniBook XE3 laptop in "c:\Apache2". After editing the httpd.conf file and adding the proper settings it seems to be working fine.

Getting PHP v4.2.1 to work in any which way or form (CGI, SAPI) however, will not work. I believe I have all the settings in the php.ini file ok.. Now I add the "LoadModule php4_module /php/sapi/php4apache2.dll" in my httpd.conf as well as the "AddType application/x-httpd-php .php" line. I've tried variations on the LoadModule line like "c:/Apache2/php/sapi/php4apache2.dll" and tried with the "php4apache.dll" as well. This pair of errors in the event log in XP will show when attempting to start the apache service:

======================================================
The Apache service named reported the following error:
>>> Cannot load C:/Apache2/php/sapi/php4apache2.dll into server: The specified module could not be found. .
======================================================
And
======================================================
The Apache service named reported the following error:
>>> Syntax error on line 173 of C:/Apache2/conf/httpd.conf: .
======================================================

And sometimes I'll get this pair of errors in the event log:

======================================================
The Apache service named reported the following error:
>>> Please contact the vendor for the correct version. .
======================================================
And
======================================================
The Apache service named reported the following error:
>>> Apache.exe: module "c:\php4build\snap\sapi\apache2filter\sapi_apache2.c" is not compatible with this version of Apache. .
======================================================

No mater what I try, this keeps showing up.. Can anyone help because I'm just POSITIVE this is something really really simple and stupid like a minute misconfiguration somewhere in some .ini or something.

Anon
07-02-2002, 08:34 PM
I'm not aware that thier is a php4apache2.dll but anyway you also need the config line "AddModule mod_php4.c" to the httpd.cong file along with the other 2 lines. The path to the dll should be the full path i.e. "c:/Apache2/php/sapi/php4apache.dll" . Hope this works for you, it worked for me but then I had the problem below so I might not have the best advice.

Anon
07-03-2002, 01:18 PM
You DON'T need "AddModule mod_php4.c" in your httpd.conf with Apache 2.x
Secondly don't try to get it to work because PHP 4.2.1/4.3.0 WON'T work with Apache 2.0.39.
That's why I'm trying to get the Apache 2.0.36 precompiled binaries for Win32.
That would be the .msi and the .asc (signature).
Apache.org only has the uncompiled version.
I need it!!! Who has it?

Anon
07-03-2002, 01:45 PM
WONT WORK?? What the hell?? The main reason I upgraded to v2.0.39 is because they resolved the chunked-encoding vulnerability that was present in previous versions of Apache that allowed a remote attacker to compromise the security of the entire system.. I refuse to revert to vulnerable versions of ANY software (not just Apache).

So then if EVEN PHP v4.3.0 won't work then what should I do???? I NEED PHP FUNCTIONALITY. I had it in BSD how come I can't have it in windows? =( .. Anyway, i'm assuming it would be possible to simply use a previous version of the compatible PHP .dll's ? Anyone?

Anon
07-03-2002, 02:17 PM
Well, I'm saying is that Apache 2.0.39 on Windows XP Pro doesn't run PHP 4.2.1 / 4.3.0

That's why I want 2.0.36.
Since my compiling skills on C++ are not much higher as "make makefile.win" I'm not very succeeding in compiling. The make command didn't work.

But you are saying you are running PHP on 2.0.39? That's maybe because of OpenBSD??

Do you know a good Windows C++ compiler?
And give me instructions to compile the 2.0.36?

Anon
07-03-2002, 07:06 PM
Try using this new dll from php.net to make php 4 work with apache 2.0.39 http://ftp.proventum.net/pub/php/win32/php4.2.x-apache2.zip
The link is from http://bugs.php.net/bug.php?id=17826

Anon
07-04-2002, 08:36 AM
It is realy a problem to have a problem with no solve!!
I am an old programer, but new to apache and PHP.
I think I tried all the ways to run PHP with apache, but failed.
......need a help...........

Anon
07-04-2002, 09:18 AM
Attention, were back in buisiness. Works with 100% PHP functionality restored =D. Thanks Joe. If the 4.2.2-dev version works then when I have time (very constricted schedule) I'll see if I can't make the 4.3.0 version myself, I'm sure it will function.