I'm trying to test cURL function with a very very simple code:
<?php
// file name : test.php
// create a new curl resource
$ch = curl_init();
// set URL and other appropriate options
curl_setopt($ch, CURLOPT_URL, "http://www.phpbuilder.com/");
curl_setopt($ch, CURLOPT_HEADER, 0);
// grab URL and pass it to the browser
curl_exec($ch);
// close curl resource, and free up system resources
curl_close($ch);
?>
And run this script with :
Then PHP said:
<br />
<b>Fatal error</b>: Call to undefined function: curl_init() in <b>test.php</b> on line <b>3</b><br />
I go to see phpinfo and found :
curl
CURL support : enabled
CURL Information : libcurl/7.10.6 OpenSSL/0.9.7a ipv6 zlib/1.1.4
What's going on with my web server. And how to solve this?
😕 😕 😕