1

I am using curl function to parse data from backpage.com and oodle.com.In backpage.com, I am using proxy, but it not working on client's server but it perfectly working on our server. But in the oodle.com proxy is not working. Is any other way to parse data from oodle.com? My code is,

$ch = curl_init();
curl_setopt($ch, CURLOPT_URL,$urls);
curl_setopt($ch, CURLOPT_PROXY, $proxy);
//curl_setopt($ch, CURLOPT_PROXYUSERPWD, $proxyauth);
curl_setopt($ch, CURLOPT_FOLLOWLOCATION, 1);
curl_setopt($ch, CURLOPT_RETURNTRANSFER, 1);
curl_setopt($ch, CURLOPT_HEADER, 1);
$original_file = curl_exec($ch);
curl_close($ch);

In client's server it shows an error

Warning: curl_setopt() [function.curl-setopt]: CURLOPT_FOLLOWLOCATION cannot be activated when safe_mode is enabled or an open_basedir is set in

I am use phpinfo(); to check the settings , the safe_mod option is off but openbase_dir have value. How can I fix this issue? Any one please help me.

Navaneetha Nair
  • 312
  • 2
  • 12
  • 1
    Do you have access to php.ini? Just find open_basedir in php.ini and clear its value. It's working as intended, the warning is quite clear. – Saeven Dec 02 '13 at 04:19
  • 1
    Try taking a look at this helpful link: http://stackoverflow.com/questions/6352927/curlopt-followlocation-cannot-be-activated – MrTechie Dec 02 '13 at 04:28

0 Answers0