
Seems to come over with double quotes escaped or something: ^iframe src=\"\" width=\"900\" height=\"450\" frameborder=\"0\" title=\"How to Save A Dying LVAD - Zachary M. "" ĭoesnt matter if I have verbose or header set to true. $header = substr($response, 0, $header_size) Įcho "HEADER SIZE: ". $header_size = curl_getinfo($ch, CURLINFO_HEADER_SIZE) Combining Large JSON Sent as Multiple Chunks.
Php curl json response code#
and still be able to use the $vimeoJSON data that I have riddled throughout my using your code sample (I know found on the net elsewhere) //temp Reading Json Curl content results in php.
Php curl json response update#

(however I do NOT get my header response data from Vimeo anymore.

I tried many ways to format the XML result as needed without luck. '' Īt this point, I -was- getting my needed header response data from Vimeo.īut the rest of the JSON data is now gone/doesnt display anymore. I need to output an array with a specif format from a cURL request. List($key, $value) = explode(':', $header, 2) Įcho "Rate Limit: ". List($headers, $body) = explode("\n\n", $response, 2) So I searched around and read that you need to add this to the cURL options/params: CURLOPT_HEADER => true,Īnd used this to break up the information: //get response header details

However, Vimeo sends back some needed data (current rate-limit and remaining limit.etc) in the HEADER RESPONSE. Which works fine when I covert to JSON and use the data output like so: $vimeoJSON = json_decode($response, true) Here, we need to pass JSON data in a URL using cURL in PHP and handle the POST request. This has been working fine, (albeit their odd 'rate limit' requirements), using the following: $curl = curl_init() ĬURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1,ĬURLOPT_HTTPHEADER => array("authorization: Bearer ".$access_token) I am using PHP/cURL to get some JSON data from Vimeo.
