Note that there are some explanatory texts on larger screens.

plurals
  1. POphp cURL CURLOPT_VERBOSE not showing payload
    primarykey
    data
    text
    <p>While the below output from curl provides useful header information, it does not provide the payload information. For example, I would want to see {"jason_index","json_value"} in the debug information provided.</p> <p>1.) Is it possible to display the payload inline with verbose mode?</p> <p>2.) What is the best way to view the sent payload that is handled by cURL? </p> <pre><code>* About to connect() to domain.com port 443 (#0) * Trying IP... * connected * Connected to domain.com (IP) port 443 (#0) * successfully set certificate verify locations: * CAfile: /usr/share/curl/curl-ca-bundle.crt CApath: none * SSL connection using RC4-SHA * Server certificate: * subject: /serialNumber=SN/C=CA/ST=Ontario/L=Ottawa/O=ORG Inc./CN=*.domain.com * start date: 2010-05-10 22:23:08 GMT * expire date: 2015-08-12 19:17:14 GMT * subjectAltName: alt.domain.com matched * issuer: /C=US/O=Equifax/OU=CA * SSL certificate verify ok. * Server auth using Basic with user 'userid' &gt; POST request_uri.json HTTP/1.1 Authorization: Basic auth_string= User-Agent: UA Host: alt.domain.com Accept: */* Content-Type: application/json; charset=utf-8 Content-Length: 85 &lt; HTTP/1.1 422 Unprocessable Entity &lt; Server: ServerName &lt; Date: Thu, 21 Mar 2013 20:08:56 GMT &lt; Content-Type: application/json; charset=utf-8 &lt; Transfer-Encoding: chunked &lt; Connection: keep-alive &lt; Status: 422 Unprocessable Entity &lt; * Connection #0 to host alt.domain.com left intact * Closing connection #0 </code></pre> <p>Example of cURL statement</p> <pre><code>$ch = curl_init(); curl_setopt($ch, CURLOPT_URL, $url); curl_setopt($ch, CURLOPT_POSTFIELDS, $data); curl_setopt($ch, CURLOPT_FOLLOWLOCATION, true); curl_setopt($ch, CURLOPT_RETURNTRANSFER, true); curl_setopt($ch, CURLOPT_VERBOSE, true); curl_setopt($ch, CURLOPT_STDERR, fopen(dirname(__FILE__) . "/headers.txt", "w+")); $result = curl_exec($ch); </code></pre>
    singulars
    1. This table or related slice is empty.
    1. This table or related slice is empty.
    plurals
    1. This table or related slice is empty.
    1. This table or related slice is empty.
    1. This table or related slice is empty.
    1. This table or related slice is empty.
 

Querying!

 
Guidance

SQuiL has stopped working due to an internal error.

If you are curious you may find further information in the browser console, which is accessible through the devtools (F12).

Reload