Skip to content

Commit d6356eb

Browse files
committed
minor #15005 [HttpClient] Fix invalid file (wkania)
This PR was merged into the 4.4 branch. Discussion ---------- [HttpClient] Fix invalid file @javiereguiluz, Small fix in your tweaks. Commits ------- 5c4e780 Fix invalid file
2 parents 9a8101f + 5c4e780 commit d6356eb

File tree

1 file changed

+11
-8
lines changed

1 file changed

+11
-8
lines changed

http_client.rst

+11-8
Original file line numberDiff line numberDiff line change
@@ -559,15 +559,18 @@ Use the ``headers`` option to define the default headers added to all requests:
559559
560560
You can also set new headers or override the default ones for specific requests:
561561

562-
.. code-block:: php
563562

564-
// this header is only included in this request and overrides the value
565-
// of the same header if defined globally by the HTTP client
566-
$response = $client->request('POST', 'https://...', [
567-
'headers' => [
568-
'Content-Type' => 'text/plain',
569-
],
570-
]);
563+
.. configuration-block::
564+
565+
.. code-block:: php
566+
567+
// this header is only included in this request and overrides the value
568+
// of the same header if defined globally by the HTTP client
569+
$response = $client->request('POST', 'https://...', [
570+
'headers' => [
571+
'Content-Type' => 'text/plain',
572+
],
573+
]);
571574
572575
Uploading Data
573576
~~~~~~~~~~~~~~

0 commit comments

Comments
 (0)