php - curl no response echo print -


i wondering why im not gettting response. uncommented curl in php.ini in php in xampp. (i found other post should uncomment curl part of php.ini in apache , php4 folder there 1 php.ini, found in php dir).

also before uncommented curl part, browser give unrecognized function error. after uncommented it, okay, guess okay in part.

<?php  $whmusername = "my_email"; $whmpassword = "my_password";  $query = "https://api.appannie.com/v1/accounts";  $ch = curl_init(); // sets url curl open curl_setopt($ch, curlopt_url, $query); // here's http auth // 3rd argument twitter username , password joined colon curl_setopt($ch, curlopt_userpwd, $whmusername." : ".$whmpassword); // makes curl_exec() return server response curl_setopt($ch, curlopt_returntransfer, true); // , here's result json $response = curl_exec($ch); curl_close($ch);  echo 'code line went here 1,';  print $response; echo $response;  echo 'code line successful here too'; ?> 

then in browser is: code line went here 1, code line successful here too

no response? or forgetting something. want able see response or json format?

here link thier api: http://support.appannie.com/entries/23224038-1-quick-start http://support.appannie.com/categories/20082753-analytics-api

also. got code here: appannie api basic authentication

can else try these please?


Comments

Popular posts from this blog

php - Calling a template part from a post -

Firefox SVG shape not printing when it has stroke -

How to mention the localhost in android -