What does "Call to undefined function: curl_init()" mean in the PHP samples?
Find the answer to your question
Please enter a search keyword.
Advanced Search
Products
Question
cURL is a PHP library used by many PHP applications to communicate with the eBay API. To use the cURL library, the cURL extension must be enabled in your PHP setup.
Answer
Detailed Description
On Windows, this typically means you just have to uncomment the cURL extension in the php.ini file. In the listing below, remove the leading semi-colon before extension=php_curl.dll to enable cURL.
From php.ini :
; Be sure to appropriately set the extension_dir directive. ;extension=php_mbstring.dll ;extension=php_bz2.dll ;extension=php_curl.dll
On Windows, you can find where your php.ini file is from phpinfo() or
by running this at the Windows command line :
C:\>php -i | find /i "php.ini" Configuration File (php.ini) Path => C:\Programs\php\php.ini C:\>
The above assumes you have php.exe in your PATH
Restart your web server after enabling cURL.
You can verify the version of cURL from a php -i or phpinfo() call :
C:\> php -i | find /i "curl" curl CURL support => enabled CURL Information => libcurl/7.14.0 OpenSSL/0.9.8a zlib/1.2.3 C:\>
Additional resources
PHP cURL library functions : http://us2.php.net/manual/en/ref.curl.php
It seems like I can’t load some PHP XML libraries. How can I troubleshoot this?
How can I debug PHP cURL sessions?
.