curl - How to properly debug PHP curl_setopt_array when it's returing false? -


code:

<?php   $this->curlhandle = curl_init();    $curl_options = $this->additionalcurloptions + array(     curlopt_cookiejar => $this->cookiefile,     curlopt_url => $base_url,     curlopt_followlocation => true,     curlopt_maxredirs => 5,     curlopt_returntransfer => true,     curlopt_ssl_verifypeer => false, // required make tests run on https.     curlopt_ssl_verifyhost => false, // required make tests run on https.     curlopt_headerfunction => array(&$this, 'curlheadercallback'),   );   if (isset($this->httpauth_credentials)) {     $curl_options[curlopt_userpwd] = $this->httpauth_credentials;   }    // curl_setopt_array() returns false if of specified options   // cannot set, , stops processing further options.   $result = curl_setopt_array($this->curlhandle, $this->additionalcurloptions + $curl_options); ?> 

i need figure out what's going wrong curl options. how debug curl_setopt_array() itself? since cookiejar (tested) working filename, url correct, header function working, , every other option hard-coded, should dig deeper?

you should use plural curl_setopt instead of singular curl_setopt_array debugging.


Comments

Popular posts from this blog

c# - DetailsView in ASP.Net - How to add another column on the side/add a control in each row? -

javascript - firefox memory leak -

Trying to import CSV file to a SQL Server database using asp.net and c# - can't find what I'm missing -