Steps for debugging php Curl on windows -


i had lot of trouble figuring out why php curl api worked fine on mac using mamp, not work under windows.

i asked fot debugging tips or useful information finding curl configuration issues under windows.

the accepted answer contains list of steps helped me curl working on windows 7 32 bits.

if curl still doesn't work, can use file_get_contents make post requests. works on hostingers, os , on local.

    $url = 'whateverurlyouwant';     $postdata = http_build_query(         array(             'id' => '202',             'form' => 'animal',             .....         )     );     $opts = array('http' =>         array(             'method'  => 'post',             'header'  => 'content-type: application/x-www-form-urlencoded',             'content' => $postdata         )     );     $context  = stream_context_create($opts);     $result = file_get_contents($url,false, $context);     echo $result 

Comments