I've got PHP installed on a windows box running IIS and I'm having some problems.

It shows no additional modules loaded.

I have:
1. set the extensions_dir in php.ini to c:\php\etc (the correct path)
2. copied every extension into windows\system32

And still phpinfo() shows no modules loaded.

Any ideas?

    Did you uncomment the ones to load in your php.ini?

      Yes, I uncommented the following line:

      extension=php_ldap.dll

        Yup - even tried rebooting the entire machine.

          I've just tracked down why some of my modules were not loading ..

          simply .. I had php.ini installed in c:\php .. and not .. c:\windows ..

          run phpinfo.php and check this line in the report ..

          Configuration File (php.ini) Path - C:\WINDOWS\php.ini

          note also ..

          PHP4 extension_dir = c:\php\extensions
          PHP5 extension_dir = c:\php\ext

            Hi,

            php_ldap.dll needs the following dlls:

            ssleay32.dll
            libeay32.dll

            Copy them to the system32 directory.

            Thomas

              I copied those, along with the php_ldap.dll to the windows/system32 directory. Still no go, getting the same error:

              Fatal error: Call to undefined function ldap_connect() in c:\Inetpub\wwwroot\ldap_p.php on line 19

              Then I copied every dll from c:\php and c:\php\ext to windows\system32 and uncommented every extension in php.ini. Still get the same error message.

              Anyone else have any ideas?

                Just wondering, what if you set:
                extension_dir = "c:/php/ext/"

                depending on webserver configs the trailing slash might make a difference.

                  ; Directory in which the loadable extensions (modules) reside.
                  extension_dir = "C:\php\ext"

                  Good idea though 🙁

                  EDIT: By the way, I tried it as:
                  C:\php\ext
                  C:\php\ext\
                  C:/php/ext
                  C:/php/ext/

                  Stopping and starting the service each time I made the change, and trying it again. Still get the same error, saying that ldap_connect() is an undefined function. I assume because the ldap module isn't loading.

                  phpinfo() still shows no "additional modules" loaded.

                    hmm... yeah, I dont think my suggestion would help much.

                    What version of MS Windows are you using?
                    What version of IIS are you using?
                    What version of PHP are you trying to install?
                    Are you going by the CGI binary or ISAPI route?

                      • Windows Server 2003
                      • IIS 6.0
                      • PHP 5.0.1 Win32 (ugh)
                      • ISAPI

                      And I know its working as via ISAPI, because php info returns the line:

                      "Server API ISAPI "

                        do you have an older copy of php.ini lurking around .. perhaps from PHP4 installation? search for all copies of php.ini and use only one. where is it located?

                          This is the first time I've ever installed it on this machine.

                          Shoot, this is the first time I've ever installed it on a box running windows.

                            I haven't read any documentation that says I need php.ini in the c:\windows directory.

                            I'll give that a shot though. I went over everything on the site, and everything is fine, still no additional modules though.

                              Well we're making progress. I had added c:\php to %path% (and rebooted) and that didn't fix it.

                              Once I dropped php.ini in the windows directory and rebooted, now accessing any .php pages generates a 500 error. So I copied a stock php.ini file over the one in windows, made two changes, and rebooted. I'll see if that fixes it here in just a minute.

                                Ok, from phpinfo():

                                extension_dir C:\php5 C:\php5

                                WHAT THE !@#$ !?

                                I know its reading php.ini from C:\WINDOWS (phpinfo() says so), in which I have the following line:

                                extension_dir="c:/php/"

                                (double checked and checked again, I only have one instance of extension_dir)

                                Why in the world is it using c:\php5 ?

                                EDIT: Just copied c:\php to c:\php5, then copied everything from c:\php5\ext and dumped it in c:\php5, stopped iisadmin and restarted w3svc, still won't show any additional modules loaded.

                                  confusing .. I know .. I've been through it myself recently on Apache2 and IIS .. but normally it isn't this difficult ..

                                  for a windows installation use the backward slash notation c:....\

                                  extension_dir = "c:\php\ext\"

                                  NOT extension_dir ="c:/php/"

                                  don't know where php5 crept in in installation but you'll have to decide which to use .. c:\php\ or c:\php5\ ..

                                  then (if the simple c:\php) .. to be consistent .. change all occurrences of c:\php5 to c:\php

                                  to be safe search throughout disk to locate c:\php5 and change to c:\php

                                  http://www.agentransack.com is a good search utility for file search

                                  but also you might search registry .. Start | Run | regedit .. Edit | Find .. c:\php5

                                  ..

                                  also have you downloaded the PECL library ?

                                  see separate "collection of PECL libraries" here (not included in PHP5 binary download)

                                  http://www.php.net/downloads.php

                                  ..

                                  to button this down .. if php_ldap fails to load .. after the above changes, download FILEMON from http://www.sysinternals.com

                                  run filemon .. setup the exclude filter in filemon to exclude all background running processes until you see an empty window (first time usage the window is full because wildcards are used) ..

                                  then setup the include filter to monitor simply ... php_ldap

                                  shut down IIS server

                                  restart IIS server

                                  and inspect filemon window to see what happens when php_ldap.dll is attempted to be loaded

                                  ..

                                  to test your PHP installation outside IIS you could try a very simple personal server from http://www.badblue.com .. which runs PHP in a matter of minutes from first installation .. then migrate to IIS when the PHP bugs are ironed out.

                                  install on some port like 8080 (not 80 if IIS is running).