cURL on Windows; no-nonsense

The dev community never seems to disappoint when it comes to writing documentation – it’s almost as if simply writing down steps in point form is too much. From what I read in the install docs of the cURL site, it’s as if it implies that it’s necessary to compile the cURL files available for download before using cURL with PHP. The PHP site, for what it’s worth, is similarly vague regarding the details of what’s needed to be able to use cURL run on Windows. Of course, I use a Linux server, but my laptop dubs as my local dev box (as I’m sure it does for most of you as well).

So – for the hopeless Googler out there looking to setup cURL on windows, this is what’s needed to be done, in step-by-step, no-nonsense English:

  1. First, I’m assuming that you’re running AppServ – a huge time saver in itself with regards to setup, it can be downloaded and installed in a very no-nonsense way:
    AppServ – Apache, PHP, MySQL, phpMyAdmin dev bundle
  2. Once you’ve installed AppServ, you need to find the following dll files and copy them to your WINDOWS\system32 directory. (”AppServ” will be the directory in which you installed AppServ, such as D:\AppServ or D:\devstuff\ApprServ or whatever)
    • AppServ\php5\ext\php_curl.dll
    • AppServ\php5\libeay.dll
    • AppServ\php5\ssleay32.dll
  3. Once you’ve done that, open up your php.ini file (if you’re using AppServ, do this by Start->Programs->AppServ->Configuration Server->”edit php ini config file”
  4. Search for “curl” and remove the ; from the beginning of it (change the line ;extension=php_curl.dll to extension=php_curl.dll
  5. Restart Apache (can be done in the AppServ start menu group as well)
  6. Check a php page that calls phpinfo() and search for “curl” – it should show up – you’re ready to go!!!

I wrote this quick guide because I’m quite frankly appalled at the lack of straightforward advice there is with respect to enabling of cURL on Windows boxes. If this helped you out, feel free to leave a comment in thanks – that’s all I ask :)

Happy scraping :D

Social Bookmarks:
  • Digg
  • del.icio.us
  • Facebook
  • Google Bookmarks
  • Live
  • Reddit
  • Technorati
  • Yahoo! Bookmarks

Leave a Reply