Ticket #7550: 7550.r8841.diff

File 7550.r8841.diff, 1.3 KB (added by jacobsantos, 5 years ago)

corrections for http.php based off of r8841.

Line 
1Index: http.php
2===================================================================
3--- http.php    (revision 8841)
4+++ http.php    (working copy)
5@@ -1024,18 +1024,14 @@
6  * The array structure is a little complex.
7  *
8  * <code>
9- * $res = array( 'headers' =>
10- *             'response' => array('code', 'message'),
11- *             'headers' => array()
12- * );
13+ * $res = array( 'headers' => array(), 'response' => array('code', 'message') );
14  * </code>
15  *
16- * All of the headers in $res['headers']['headers'] are with the name as the key
17- * and the value as the value. So to get the User-Agent, you would do the
18- * following.
19+ * All of the headers in $res['headers'] are with the name as the key and the
20+ * value as the value. So to get the User-Agent, you would do the following.
21  *
22  * <code>
23- * $user_agent = $res['headers']['headers']['user-agent'];
24+ * $user_agent = $res['headers']['user-agent'];
25  * </code>
26  *
27  * The body is the raw response content and can be retrieved from $res['body'].
28@@ -1043,7 +1039,7 @@
29  * This function is called first to make the request and there are other API
30  * functions to abstract out the above convoluted setup.
31  *
32- * @since 2.7
33+ * @since 2.7.0
34  *
35  * @param string $url Site URL to retrieve.
36  * @param array $args Optional. Override the defaults.