Warning: curl_setopt() [function.curl-setopt]: CURLOPT_FOLLOWLOCATION cannot be activated when in safe_mod开发者_如何学JAVAe or an open_basedir is set in /home/public_html/curl.php on line
Trying to use curl_setopt ($ch, CURLOPT_FOLLOWLOCATION, TRUE);
but I'm getting this error. How can I overcome it?
This is because your setup has either safe mode or open_basedir settings in the php.ini.
You need to change these settings in the php.ini to do this.
Try adding
curl_setopt($ch, CURLOPT_HEADER, 0);
精彩评论