"Lewis Burden" <lb004a8267_2 RemoveThis @blueyonder.co.uk> wrote in message
news:zeYJb.13865$Od5.13065@news-binary.blueyonder.co.uk...
> I have just installed apache and php on windows 98
> and added the following lines to the apache httpd.conf
>
> ScriptAlias /php/ "C:/php"
What would you want that for ?
> AddType application/x-httpd-php .php
That's good.
> Action application/x-httpd-php "/php/php.exe"
This loads the CGI version of php. You probably don't want that.
>
> LoadModule php4_module modules/php4ts.dll
This looks like the command to load the Apache PHP4 module. But there are
two things wrong with it: 1) It loads the wrong dll 2) You can't have PHP
active both as a CGI version and as an Apache module.
Resolution:
-----------
php4ts.dll needs to be copied to c:\windows\system (and just left there).
the LoadModule line should load the Apache PHP module, not the php4 dll:
--> LoadModule php4_module c:/php/sapi/php4apache.dll
# For Apache 1.3.x
or
--> LoadModule php4_module c:/php/sapi/php4apache2.dll
# For Apache 2.0.x, which I assume you're running
(of course you should change the path to the php directory if php is
installed anywhere else)
> AddType application/x-httpd-php .php
>
> But when I run the apache server I get this error message
>
> Cannot load c:/program files/apache group/apache/module/php4ts.dll into
> server: (1157) One of the library files needed to run this application
> cannot be found.
>
> the php4ts.dll is in 4 places on my machine
That only leads to confusion. Just leave it in c:\php put a copy in
c:\windows\system.
>
> c:\php
> c:\windows
> c:\windows\system
> c:\windows\system32
>
> Please help!!
Read the documentation!! It's there for a purpose!
Here is a working PHP config for Apache 2.0.x:
httpd.conf:
-----------
--> LoadModule php4_module c:/php/sapi/php4apache2.dll
....
--> AddType application/x-httpd-php .php
That's really all.
Jeroen.<!-- ~MESSAGE_AFTER~ -->
>> Stay informed about: 1157