Hello everyone,

I'm pretty new to this site, so i apologize for my n00bishness.

My webserver is:
Windows 2k3 w/ sp1
IIS 6
PHP 5.1.4

I'm trying to get cURL to work, but with no avail.

This is what I've done.

First of all i got a basic HTML page working. So i know IIS is working okay.

Second to get PHP working i did the follow (and it worked):

1. Download PHP at http://www.php.net/downloads.php. Make sure you dowload the "zip package", the installer package won't work.

  1. Extract the downloaded zip file to a directory of choice on your harddrive. The rest of this guide will assume you are using C:\PHP

  2. Add C:\PHP to your path. From the Start menu, right click My Computer and select Properties. From the Advanced tab click the Environment Variables button. Under System Variable find Path and click Edit. At the end of what is already present in Variable Value add a semicolon ( and then C:\PHP.

  3. Configure IIS. Open the Internet Information Services (IIS) Manager from Administrative Tools (found directly in the Start menu or in the Control Panel)

a) Web Service Extension. Click down to the Web Service Extension folder. Right click the folder and select Add New Web Service Extension. Set Extension Name to PHP and add C:\PHP\PHP5ISAPI.DLL to Required Files . Check Set Extension Status To Allowed.

b) Web Sites. Click down to Web Sites. Right click the folder and select Properties. From the Home Directory tab click the Configuration button. Click Add to add an Application Extension. Enter C:\PHP\PHP5ISAPI.DLL as Executable and PHP as Extension. Leave the rest as default and click Ok.

  1. All set! To test your PHP installation simply create text a file with the php extension, eg. test.php. Add the following three lines of text to it and then save it to your web site directory, eg. C:\INETPUB\WWWROOT. Then use your browser to read the file, eg. http://localhost/test.php
    <?php
    phpinfo();
    ?> [/I]

I got that info from:
http://www.tjitjing.com/blog/2006/05/php5-with-iis6-on-windows-server-2003.html

http://localhost/test.php

When i go to the link above (localhost link) the PHP info page pulls up perfectly.

Now from C:\PHP i copy pasted php.ini-dist into C:\Windows and renamed it php.ini

Within the php.ini i changed two things:
1. extension_dir = "C:\PHP\ext\"
2. And i uncommented the "extension=php_curl.dll

I also copy-pasted the libeay.dll into C:\Windows\System32

rebooted my Windows 2003 box, tried

http://localhost/test.php

Again, it came up but there is NO mention of "curl" anywhere on that page!

HELP! Please! 😕
rudy

    Couple of things.

    1. The method of copying various DLLs to the system32 folder is depcreated. Here's a quote from the man page [man]install.windows.extensions[/man]:

      Some of the extensions need extra DLLs to work. Couple of them can be found in the distribution package, in the C:\php\dlls\ folder in PHP 4 or in the main folder in PHP 5, but some, for example Oracle (php_oci8.dll) require DLLs which are not bundled with the distribution package. If you are installing PHP 4, copy the bundled DLLs from C:\php\dlls folder to the main C:\php folder. Don't forget to include C:\php in the system PATH (this process is explained in a separate FAQ entry).

    2. The two required DLLs listed on that same manual page for php_curl.dll are: libeay32.dll, ssleay32.dll

    3. You did double check the path to the extensions directory, and verified that the DLL is in there, right?

    4. To rule out permissions issues, did you try manually add the "IUSR_ComputerName" user to the Access Control List (ACL) on the security tab of the C:\PHP\ folder and giving this user all of the read access types to it (or even full control)?

    5. Have you tried setting the directive "display_startup_errors" to On?

    EDIT: Also, welcome to PHPBuilder 🙂

      1. Okay, I took the two dlls i added into the system32 folder. I quadruple checked my system path in System Properties -> Advance Tab -> Enviromental Variables button. and C:\PHP is in there. I even added it to the beginning of the Path.

      2. libeay32.dll, ssleay32.dll are in C:\PHP\

      3. the line in my c:\windows\php.ini reads:
        extension_dir = "C:\PHP\ext\"

      4. Okay, did this...and no luck.

      5. I set display_startup_errors=on

      then restarted.

      i ran phpinfo(); on a page i have called http://localhost/test.php

      and i see two notable things:

      (a)

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

      (b)

      display_startup_errors Off Off

      wtf!? why isn't it loading my php.ini (which i assume is the problem!)

      thanks in advance for any help ya'll,
      rudy 🙂

        So your php.ini file is truly in C:\WINDOWS\ ? Do you have file extensions shown, so it's not actually php.ini.txt ?

        And by "restarted" I assume you did a full restart of IIS at least?

          Yeah, my php.ini (i know it's an ini file and not a txt file, because it looks like the rest of the ini files...a little notepad icon with a cog wheel). They way the icon looks assures me that it's actually an ini file. Also i have view file extentions, and i sort it by "Type" in Windows Explorer.

          Also by restart, i mean, a reboot of the entire machine. I go to start -> shut down -> restart

          No idea why it's not picking up my php.ini :-(....I've also search the entire drive and there is no other php.ini! There are the php.ini-dist and php.ini-recommended that come in PHP but those aren't even a ".ini" extension!

          Thanks again,
          rudy

            Also....i forgot to mention this, sorry.

            My first post has 5 italized steps that i did to get PHP working. When following those step (mainly noted in step 5) when i run my test.php page it comes up fine! no errors! Only after that is when i added php.ini to the c:\windows.

            So w/o php.ini being in C:\windows.....phpinfo(); was still working!!! how!? I have no idea!!!

            Arrgg! this is so confusing/frustrating!

            help!
            rudy

            (and thanks again!)

              wow i feel like a freaking idiot.

              I got it resolved...how you might ask?

              "Some tutorials state that you need to restart the World Wide Web Publishing Service after having installed and configured php. I haven't needed to (ie everything worked fine without restarting the service) but if you do it is found under Services in the [Administrative Tools] in the Control Panel."
              - http://www.tjitjing.com/blog/2006/05/php5-with-iis6-on-windows-server-2003.html

              By far the easiest tutorial to do/follow and it took me like a week to get this up and running....I'm so sad.

              LEARN FROM MY STUPIDITY!
              rudy

                Write a Reply...