/**
* The charset encoding that will be used for serializing request sent by the client.
- * If defaults to NULL, which means using US-ASCII and encoding all characters outside of the ASCII range using
+ * It defaults to NULL, which means using US-ASCII and encoding all characters outside of the ASCII range using
* their xml character entity representation (this has the benefit that line end characters will not be mangled in
* the transfer, a CR-LF will be preserved as well as a singe LF).
* Valid values are 'US-ASCII', 'UTF-8' and 'ISO-8859-1'
$headers[] = $encodingHdr;
}
+ // Fix the HTTP/1.1 417 Expectation Failed Bug (curl by default adds a 'Expect: 100-continue' header when POST
+ // size exceeds 1025 bytes, apparently)
+ $headers[] = 'Expect:';
+
curl_setopt($curl, CURLOPT_HTTPHEADER, $headers);
// timeout is borked
if ($timeout) {