Edit report at https://bugs.php.net/bug.php?id=61346&edit=1
ID: 61346 Updated by: il...@php.net Reported by: l dot declercq at nuxwin dot com Summary: CURL_HTTP_VERSION_1_0 bypassed when using CURLINFO_HEADER_OUT -Status: Open +Status: Not a bug Type: Bug Package: cURL related Operating System: Debian Squeeze PHP Version: Irrelevant Block user comment: N Private report: N New Comment: Sorry, but your problem does not imply a bug in PHP itself. For a list of more appropriate places to ask for help using PHP, please visit http://www.php.net/support.php as this bug system is not the appropriate forum for asking support questions. Due to the volume of reports we can not explain in detail here why your report is not a bug. The support channels will be able to provide an explanation for you. Thank you for your interest in PHP. The change is triggered by libcurl not PHP. Previous Comments: ------------------------------------------------------------------------ [2012-03-11 00:29:37] l dot declercq at nuxwin dot com Description: ------------ When using the CURLINFO_HEADER_OUT option HTTP version option seem to be bypassed (1.1 is forced) Test script: --------------- // ... curl_setopt($curlSession, CURLINFO_HEADER_OUT, true); // Mark as HTTP request curl_setopt($curlSession, CURL_HTTP_VERSION_1_0, true); // ... // Send the request $response = curl_exec($curlSession); $request = curl_getinfo($curlSession, CURLINFO_HEADER_OUT); echo $request Expected result: ---------------- // kind of GET /rest.php?wsid=boxbilling&method=sayHello&name=Declercq%20Lau%3Frent HTTP/1.0 Accept: */* X-Requested-With: RestHttpRequest Host: imscp.i-mscp.net Connection: close Accept-encoding: identity User-Agent: iMSCP_Rest_Client Authorization: Basic YWRtaW4xOmFkbWluMQ== Actual result: -------------- GET /rest.php?wsid=boxbilling&method=sayHello&name=Declercq%20Lau%3Frent HTTP/1.1 Accept: */* X-Requested-With: RestHttpRequest Host: imscp.i-mscp.net Connection: close Accept-encoding: identity User-Agent: iMSCP_Rest_Client Authorization: Basic YWRtaW4xOmFkbWluMQ== ------------------------------------------------------------------------ -- Edit this bug report at https://bugs.php.net/bug.php?id=61346&edit=1