I can get PERL and Python to work with Apache, but not PHP. I have read through a few install guides and this is the relevant parts to PHP in my httpd.conf:

Notes:
php.exe is in
c:_\pre-configured_programs\php\
apache.exe is in
C:_\pre-configured_programs\apache\

(don't ask me why I chose those dir)

ScriptAlias /php/ "c:/_/pre-configured_programs/php/"

AddType application/x-httpd-php .php .php3 .phtml
AddType application/x-httpd-php-source .phps

Action application/x-httpd-php c:/_/pre-configured_programs/php/php.exe

I've placed the php.ini in the windows directory + moved required dlls to c:\windows\system and changed
extension_dir in php.ini to point to the php directory. I'm stumped. Please help.

    are you set on using php.exe as a CGI? cuz if you're open to configuring using the SAPI dll's I do know how to that at least working =P

      I think I will try the ISAPI dlls now. Maybe I'll try using php.exe as a CGI when I learn more about Apache and PHP, once I get them running together. I'll read through the install guides for the ISAPI dlls and see how I go.

        I saved the Apache and PHP directories in a directory before re-installing windows, so all the windows registry information about the two would of disappeared. I guess that was the problem, because when using the Apache and PHP installers (php404.exe) I have no problems. I wish I knew the relevant registry information, so that when I re-install windows (which I need to do too frequently, being a windows user) I could have Perl, Python (both only need a line of registry information) and PHP ready to go with Apache. I know there is a PHP install that lets you just click on a .reg file to enter the windows registry information. I'll try and find that install and see if I can get what I need to get when I have to re-install windows again (notice when, not if lol).

          right, but the less you have to do is always better =)

          I actually use the zip file for PHP, because when using the .msi, there is not the option of using ISAPI support (at least not atm), which i prefer.

          When using the zip verions, you basically are only installing the files and directories needed for PHP to exist, but not run. You have to manually configure both the Apache httpd.conf and the php.ini to get them to work correctly in windows.

          It is not especially difficult, there is no risk of f'ing up the registry, and you actually then learn by osmosis how the stuff is really working. Also, its just a bias of mine, since I am doing this all, ostensibly, as a project for future installs on my linux box, which except for the make/install/configure (which is basically building your own registry settings... in a linux sort of way... very loose analogy) is somewhat similar in that you unzip/tar the packages, then edit the httpd.conf and php.ini and voila, ur up and running.

          Ive now pulled out so much hair in teaching myself this configuration (Win/Apache/PHP via ISAPI/Mysql) that I finally now feel comfortable enough redoing it over and over w/ minimal... "WTH?"'s I can usually think over it and say to self, "Oh duh.. remember you did this last time too dopey."

          anyway, if you would like to try the Win/Apache/PHP via ISAPI/MySql route, then lemme know, my name/sig is my email addy and am more than willing to help out.

          =)

            Thanks for your information. I might try the ISAPI/MySQL route within the next week. And I'll contact you if I am stuck, thanks.

              Write a Reply...