reference/curl/functions/curl-getinfo.xml
8b3f89ed6171cb711b00afb0fcacbea3462537b9
...
...
@@ -1,6 +1,6 @@
1
1
<?xml version="1.0" encoding="utf-8"?>
2
2
<!-- $Revision$ -->
3
-
<refentry xml:id='function.curl-getinfo' xmlns="http://docbook.org/ns/docbook">
3
+
<refentry xml:id="function.curl-getinfo" xmlns="http://docbook.org/ns/docbook">
4
4
<refnamediv>
5
5
<refname>curl_getinfo</refname>
6
6
<refpurpose>Get information regarding a specific transfer</refpurpose>
...
...
@@ -10,8 +10,8 @@
10
10
&reftitle.description;
11
11
<methodsynopsis>
12
12
<type>mixed</type><methodname>curl_getinfo</methodname>
13
-
<methodparam><type>resource</type><parameter>ch</parameter></methodparam>
14
-
<methodparam choice="opt"><type>int</type><parameter>opt</parameter></methodparam>
13
+
<methodparam><type>CurlHandle</type><parameter>handle</parameter></methodparam>
14
+
<methodparam choice="opt"><type class="union"><type>int</type><type>null</type></type><parameter>option</parameter><initializer>&null;</initializer></methodparam>
15
15
</methodsynopsis>
16
16
<para>
17
17
Gets information about the last transfer.
...
...
@@ -24,321 +24,550 @@
24
24
<variablelist>
25
25
&curl.ch.description;
26
26
<varlistentry>
27
-
<term><parameter>opt</parameter></term>
27
+
<term><parameter>option</parameter></term>
28
28
<listitem>
29
29
<para>
30
30
This may be one of the following constants:
31
-
<itemizedlist>
32
-
<listitem>
33
-
<simpara>
34
-
<constant>CURLINFO_EFFECTIVE_URL</constant> - Last effective URL
35
-
</simpara>
36
-
</listitem>
37
-
<listitem>
38
-
<simpara>
39
-
<constant>CURLINFO_HTTP_CODE</constant> - The last response code.
40
-
As of PHP 5.5.0 and cURL 7.10.8, this is a legacy alias of
41
-
<constant>CURLINFO_RESPONSE_CODE</constant>
42
-
</simpara>
43
-
</listitem>
44
-
<listitem>
45
-
<simpara>
46
-
<constant>CURLINFO_FILETIME</constant> - Remote time of the retrieved document, with the <constant>CURLOPT_FILETIME</constant> enabled; if -1 is returned the time of the document is unknown
47
-
</simpara>
48
-
</listitem>
49
-
<listitem>
50
-
<simpara>
51
-
<constant>CURLINFO_TOTAL_TIME</constant> - Total transaction time in seconds for last transfer
52
-
</simpara>
53
-
</listitem>
54
-
<listitem>
55
-
<simpara>
56
-
<constant>CURLINFO_NAMELOOKUP_TIME</constant> - Time in seconds until name resolving was complete
57
-
</simpara>
58
-
</listitem>
59
-
<listitem>
60
-
<simpara>
61
-
<constant>CURLINFO_CONNECT_TIME</constant> - Time in seconds it took to establish the connection
62
-
</simpara>
63
-
</listitem>
64
-
<listitem>
65
-
<simpara>
66
-
<constant>CURLINFO_PRETRANSFER_TIME</constant> - Time in seconds from start until just before file transfer begins
67
-
</simpara>
68
-
</listitem>
69
-
<listitem>
70
-
<simpara>
71
-
<constant>CURLINFO_STARTTRANSFER_TIME</constant> - Time in seconds until the first byte is about to be transferred
72
-
</simpara>
73
-
</listitem>
74
-
<listitem>
75
-
<simpara>
76
-
<constant>CURLINFO_REDIRECT_COUNT</constant> - Number of redirects, with the <constant>CURLOPT_FOLLOWLOCATION</constant> option enabled
77
-
</simpara>
78
-
</listitem>
79
-
<listitem>
80
-
<simpara>
81
-
<constant>CURLINFO_REDIRECT_TIME</constant> - Time in seconds of all redirection steps before final transaction was started, with the <constant>CURLOPT_FOLLOWLOCATION</constant> option enabled
82
-
</simpara>
83
-
</listitem>
84
-
<listitem>
85
-
<simpara>
86
-
<constant>CURLINFO_REDIRECT_URL</constant> - With the <constant>CURLOPT_FOLLOWLOCATION</constant> option disabled: redirect URL found in the last transaction, that should be requested manually next. With the <constant>CURLOPT_FOLLOWLOCATION</constant> option enabled: this is empty. The redirect URL in this case is available in <constant>CURLINFO_EFFECTIVE_URL</constant>
87
-
</simpara>
88
-
</listitem>
89
-
<listitem>
90
-
<simpara>
91
-
<constant>CURLINFO_PRIMARY_IP</constant> - IP address of the most recent connection
92
-
</simpara>
93
-
</listitem>
94
-
<listitem>
95
-
<simpara>
96
-
<constant>CURLINFO_PRIMARY_PORT</constant> - Destination port of the most recent connection
97
-
</simpara>
98
-
</listitem>
99
-
<listitem>
100
-
<simpara>
101
-
<constant>CURLINFO_LOCAL_IP</constant> - Local (source) IP address of the most recent connection
102
-
</simpara>
103
-
</listitem>
104
-
<listitem>
105
-
<simpara>
106
-
<constant>CURLINFO_LOCAL_PORT</constant> - Local (source) port of the most recent connection
107
-
</simpara>
108
-
</listitem>
109
-
<listitem>
110
-
<simpara>
111
-
<constant>CURLINFO_SIZE_UPLOAD</constant> - Total number of bytes uploaded
112
-
</simpara>
113
-
</listitem>
114
-
<listitem>
115
-
<simpara>
116
-
<constant>CURLINFO_SIZE_DOWNLOAD</constant> - Total number of bytes downloaded
117
-
</simpara>
118
-
</listitem>
119
-
<listitem>
120
-
<simpara>
121
-
<constant>CURLINFO_SPEED_DOWNLOAD</constant> - Average download speed
122
-
</simpara>
123
-
</listitem>
124
-
<listitem>
125
-
<simpara>
126
-
<constant>CURLINFO_SPEED_UPLOAD</constant> - Average upload speed
127
-
</simpara>
128
-
</listitem>
129
-
<listitem>
130
-
<simpara>
131
-
<constant>CURLINFO_HEADER_SIZE</constant> - Total size of all headers received
132
-
</simpara>
133
-
</listitem>
134
-
<listitem>
135
-
<simpara>
136
-
<constant>CURLINFO_HEADER_OUT</constant> - The request string sent. For this to
137
-
work, add the <constant>CURLINFO_HEADER_OUT</constant> option to the handle by calling
138
-
<function>curl_setopt</function>
139
-
</simpara>
140
-
</listitem>
141
-
<listitem>
142
-
<simpara>
143
-
<constant>CURLINFO_REQUEST_SIZE</constant> - Total size of issued requests, currently only for HTTP requests
144
-
</simpara>
145
-
</listitem>
146
-
<listitem>
147
-
<simpara>
148
-
<constant>CURLINFO_SSL_VERIFYRESULT</constant> - Result of SSL certification verification requested by setting <constant>CURLOPT_SSL_VERIFYPEER</constant>
149
-
</simpara>
150
-
</listitem>
151
-
<listitem>
152
-
<simpara>
153
-
<constant>CURLINFO_CONTENT_LENGTH_DOWNLOAD</constant> - Content length of download, read from <literal>Content-Length:</literal> field
154
-
</simpara>
155
-
</listitem>
156
-
<listitem>
157
-
<simpara>
158
-
<constant>CURLINFO_CONTENT_LENGTH_UPLOAD</constant> - Specified size of upload
159
-
</simpara>
160
-
</listitem>
161
-
<listitem>
162
-
<simpara>
163
-
<constant>CURLINFO_CONTENT_TYPE</constant> - <literal>Content-Type:</literal> of the requested document. NULL indicates server did not send valid <literal>Content-Type:</literal> header
164
-
</simpara>
165
-
</listitem>
166
-
<listitem>
167
-
<simpara>
168
-
<constant>CURLINFO_PRIVATE</constant> - Private data associated with this cURL handle, previously set with the <constant>CURLOPT_PRIVATE</constant> option of <function>curl_setopt</function>
169
-
</simpara>
170
-
</listitem>
171
-
<listitem>
172
-
<simpara>
173
-
<constant>CURLINFO_RESPONSE_CODE</constant> - The last response code
174
-
</simpara>
175
-
</listitem>
176
-
<listitem>
177
-
<simpara>
178
-
<constant>CURLINFO_HTTP_CONNECTCODE</constant> - The CONNECT response code
179
-
</simpara>
180
-
</listitem>
181
-
<listitem>
182
-
<simpara>
183
-
<constant>CURLINFO_HTTPAUTH_AVAIL</constant> - Bitmask indicating the authentication method(s) available according to the previous response
184
-
</simpara>
185
-
</listitem>
186
-
<listitem>
187
-
<simpara>
188
-
<constant>CURLINFO_PROXYAUTH_AVAIL</constant> - Bitmask indicating the proxy authentication method(s) available according to the previous response
189
-
</simpara>
190
-
</listitem>
191
-
<listitem>
192
-
<simpara>
193
-
<constant>CURLINFO_OS_ERRNO</constant> - Errno from a connect failure. The number is OS and system specific.
194
-
</simpara>
195
-
</listitem>
196
-
<listitem>
197
-
<simpara>
198
-
<constant>CURLINFO_NUM_CONNECTS</constant> - Number of connections curl had to create to achieve the previous transfer
199
-
</simpara>
200
-
</listitem>
201
-
<listitem>
202
-
<simpara>
203
-
<constant>CURLINFO_SSL_ENGINES</constant> - OpenSSL crypto-engines supported
204
-
</simpara>
205
-
</listitem>
206
-
<listitem>
207
-
<simpara>
208
-
<constant>CURLINFO_COOKIELIST</constant> - All known cookies
209
-
</simpara>
210
-
</listitem>
211
-
<listitem>
212
-
<simpara>
213
-
<constant>CURLINFO_FTP_ENTRY_PATH</constant> - Entry path in FTP server
214
-
</simpara>
215
-
</listitem>
216
-
<listitem>
217
-
<simpara>
218
-
<constant>CURLINFO_APPCONNECT_TIME</constant> - Time in seconds it took from the start until the SSL/SSH connect/handshake to the remote host was completed
219
-
</simpara>
220
-
</listitem>
221
-
<listitem>
222
-
<simpara>
223
-
<constant>CURLINFO_CERTINFO</constant> - TLS certificate chain
224
-
</simpara>
225
-
</listitem>
226
-
<listitem>
227
-
<simpara>
228
-
<constant>CURLINFO_CONDITION_UNMET</constant> - Info on unmet time conditional
229
-
</simpara>
230
-
</listitem>
231
-
<listitem>
232
-
<simpara>
233
-
<constant>CURLINFO_RTSP_CLIENT_CSEQ</constant> - Next RTSP client CSeq
234
-
</simpara>
235
-
</listitem>
236
-
<listitem>
237
-
<simpara>
238
-
<constant>CURLINFO_RTSP_CSEQ_RECV</constant> - Recently received CSeq
239
-
</simpara>
240
-
</listitem>
241
-
<listitem>
242
-
<simpara>
243
-
<constant>CURLINFO_RTSP_SERVER_CSEQ</constant> - Next RTSP server CSeq
244
-
</simpara>
245
-
</listitem>
246
-
<listitem>
247
-
<simpara>
248
-
<constant>CURLINFO_RTSP_SESSION_ID</constant> - RTSP session ID
249
-
</simpara>
250
-
</listitem>
251
-
<listitem>
252
-
<simpara>
253
-
<constant>CURLINFO_CONTENT_LENGTH_DOWNLOAD_T</constant> - The content-length of the download. This is the value read from the <literal>Content-Type:</literal> field. -1 if the size isn't known
254
-
</simpara>
255
-
</listitem>
256
-
<listitem>
257
-
<simpara>
258
-
<constant>CURLINFO_CONTENT_LENGTH_UPLOAD_T</constant> - The specified size of the upload. -1 if the size isn't known
259
-
</simpara>
260
-
</listitem>
261
-
<listitem>
262
-
<simpara>
263
-
<constant>CURLINFO_HTTP_VERSION</constant> - The version used in the last HTTP connection. The return value will be one of the defined <constant>CURL_HTTP_VERSION_*</constant> constants or 0 if the version can't be determined
264
-
</simpara>
265
-
</listitem>
266
-
<listitem>
267
-
<simpara>
268
-
<constant>CURLINFO_PROTOCOL</constant> - The protocol used in the last HTTP connection. The returned value will be exactly one of the <constant>CURLPROTO_*</constant> values
269
-
</simpara>
270
-
</listitem>
271
-
<listitem>
272
-
<simpara>
273
-
<constant>CURLINFO_PROXY_SSL_VERIFYRESULT</constant> - The result of the certificate verification that was requested (using the <constant>CURLOPT_PROXY_SSL_VERIFYPEER</constant> option). Only used for HTTPS proxies
274
-
</simpara>
275
-
</listitem>
276
-
<listitem>
277
-
<simpara>
278
-
<constant>CURLINFO_SCHEME</constant> - The URL scheme used for the most recent connection
279
-
</simpara>
280
-
</listitem>
281
-
<listitem>
282
-
<simpara>
283
-
<constant>CURLINFO_SIZE_DOWNLOAD_T</constant> - Total number of bytes that were downloaded. The number is only for the latest transfer and will be reset again for each new transfer
284
-
</simpara>
285
-
</listitem>
286
-
<listitem>
287
-
<simpara>
288
-
<constant>CURLINFO_SIZE_UPLOAD_T</constant> - Total number of bytes that were uploaded
289
-
</simpara>
290
-
</listitem>
291
-
<listitem>
292
-
<simpara>
293
-
<constant>CURLINFO_SPEED_DOWNLOAD_T</constant> - The average download speed in bytes/second that curl measured for the complete download
294
-
</simpara>
295
-
</listitem>
296
-
<listitem>
297
-
<simpara>
298
-
<constant>CURLINFO_SPEED_UPLOAD_T</constant> - The average upload speed in bytes/second that curl measured for the complete upload
299
-
</simpara>
300
-
</listitem>
301
-
<listitem>
302
-
<simpara>
303
-
<constant>CURLINFO_APPCONNECT_TIME_T</constant> - Time, in microseconds, it took from the start until the SSL/SSH connect/handshake to the remote host was completed
304
-
</simpara>
305
-
</listitem>
306
-
<listitem>
307
-
<simpara>
308
-
<constant>CURLINFO_CONNECT_TIME_T</constant> - Total time taken, in microseconds, from the start until the connection to the remote host (or proxy) was completed
309
-
</simpara>
310
-
</listitem>
311
-
<listitem>
312
-
<simpara>
313
-
<constant>CURLINFO_FILETIME_T</constant> - Remote time of the retrieved document (as Unix timestamp), an alternative to <constant>CURLINFO_FILETIME</constant> to allow systems with 32 bit long variables to extract dates outside of the 32bit timestamp range
314
-
</simpara>
315
-
</listitem>
316
-
<listitem>
317
-
<simpara>
318
-
<constant>CURLINFO_NAMELOOKUP_TIME_T</constant> - Time in microseconds from the start until the name resolving was completed
319
-
</simpara>
320
-
</listitem>
321
-
<listitem>
322
-
<simpara>
323
-
<constant>CURLINFO_PRETRANSFER_TIME_T</constant> - Time taken from the start until the file transfer is just about to begin, in microseconds
324
-
</simpara>
325
-
</listitem>
326
-
<listitem>
327
-
<simpara>
328
-
<constant>CURLINFO_REDIRECT_TIME_T</constant> - Total time, in microseconds, it took for all redirection steps include name lookup, connect, pretransfer and transfer before final transaction was started
329
-
</simpara>
330
-
</listitem>
331
-
<listitem>
332
-
<simpara>
333
-
<constant>CURLINFO_STARTTRANSFER_TIME_T</constant> - Time, in microseconds, it took from the start until the first byte is received
334
-
</simpara>
335
-
</listitem>
336
-
<listitem>
337
-
<simpara>
338
-
<constant>CURLINFO_TOTAL_TIME_T</constant> - Total time in microseconds for the previous transfer, including name resolving, TCP connect etc.
339
-
</simpara>
340
-
</listitem>
341
-
</itemizedlist>
31
+
<informaltable>
32
+
<tgroup cols="3">
33
+
<thead>
34
+
<row>
35
+
<entry valign="top">Option</entry>
36
+
<entry valign="top">&Description;</entry>
37
+
</row>
38
+
</thead>
39
+
<tbody>
40
+
<row>
41
+
<entry valign="top">
42
+
<constant>CURLINFO_CAINFO</constant>
43
+
</entry>
44
+
<entry valign="top">
45
+
Default built-in CA certificate path
46
+
</entry>
47
+
</row>
48
+
<row>
49
+
<entry valign="top">
50
+
<constant>CURLINFO_CAPATH</constant>
51
+
</entry>
52
+
<entry valign="top">
53
+
Default built-in CA path string
54
+
</entry>
55
+
</row>
56
+
<row>
57
+
<entry valign="top">
58
+
<constant>CURLINFO_EFFECTIVE_URL</constant>
59
+
</entry>
60
+
<entry valign="top">
61
+
Last effective URL
62
+
</entry>
63
+
</row>
64
+
<row>
65
+
<entry valign="top">
66
+
<constant>CURLINFO_HTTP_CODE</constant>
67
+
</entry>
68
+
<entry valign="top">
69
+
The last response code. As of cURL 7.10.8, this is a legacy alias of CURLINFO_RESPONSE_CODE
70
+
</entry>
71
+
</row>
72
+
<row>
73
+
<entry valign="top">
74
+
<constant>CURLINFO_FILETIME</constant>
75
+
</entry>
76
+
<entry valign="top">
77
+
Remote time of the retrieved document, with the CURLOPT_FILETIME enabled; if -1 is returned the time of the document is unknown
78
+
</entry>
79
+
</row>
80
+
<row>
81
+
<entry valign="top">
82
+
<constant>CURLINFO_TOTAL_TIME</constant>
83
+
</entry>
84
+
<entry valign="top">
85
+
Total transaction time in seconds for last transfer
86
+
</entry>
87
+
</row>
88
+
<row>
89
+
<entry valign="top">
90
+
<constant>CURLINFO_NAMELOOKUP_TIME</constant>
91
+
</entry>
92
+
<entry valign="top">
93
+
Time in seconds until name resolving was complete
94
+
</entry>
95
+
</row>
96
+
<row>
97
+
<entry valign="top">
98
+
<constant>CURLINFO_CONNECT_TIME</constant>
99
+
</entry>
100
+
<entry valign="top">
101
+
Time in seconds it took to establish the connection
102
+
</entry>
103
+
</row>
104
+
<row>
105
+
<entry valign="top">
106
+
<constant>CURLINFO_PRETRANSFER_TIME</constant>
107
+
</entry>
108
+
<entry valign="top">
109
+
Time in seconds from start until just before file transfer begins
110
+
</entry>
111
+
</row>
112
+
<row>
113
+
<entry valign="top">
114
+
<constant>CURLINFO_STARTTRANSFER_TIME</constant>
115
+
</entry>
116
+
<entry valign="top">
117
+
Time in seconds until the first byte is about to be transferred
118
+
</entry>
119
+
</row>
120
+
<row>
121
+
<entry valign="top">
122
+
<constant>CURLINFO_REDIRECT_COUNT</constant>
123
+
</entry>
124
+
<entry valign="top">
125
+
Number of redirects, with the CURLOPT_FOLLOWLOCATION option enabled
126
+
</entry>
127
+
</row>
128
+
<row>
129
+
<entry valign="top">
130
+
<constant>CURLINFO_REDIRECT_TIME</constant>
131
+
</entry>
132
+
<entry valign="top">
133
+
Time in seconds of all redirection steps before final transaction was started, with the CURLOPT_FOLLOWLOCATION option enabled
134
+
</entry>
135
+
</row>
136
+
<row>
137
+
<entry valign="top">
138
+
<constant>CURLINFO_REDIRECT_URL</constant>
139
+
</entry>
140
+
<entry valign="top">
141
+
With the CURLOPT_FOLLOWLOCATION option disabled: redirect URL found in the last transaction, that should be requested manually next. With the CURLOPT_FOLLOWLOCATION option enabled: this is empty. The redirect URL in this case is available in CURLINFO_EFFECTIVE_URL
142
+
</entry>
143
+
</row>
144
+
<row>
145
+
<entry valign="top">
146
+
<constant>CURLINFO_PRIMARY_IP</constant>
147
+
</entry>
148
+
<entry valign="top">
149
+
IP address of the most recent connection
150
+
</entry>
151
+
</row>
152
+
<row>
153
+
<entry valign="top">
154
+
<constant>CURLINFO_PRIMARY_PORT</constant>
155
+
</entry>
156
+
<entry valign="top">
157
+
Destination port of the most recent connection
158
+
</entry>
159
+
</row>
160
+
<row>
161
+
<entry valign="top">
162
+
<constant>CURLINFO_LOCAL_IP</constant>
163
+
</entry>
164
+
<entry valign="top">
165
+
Local (source) IP address of the most recent connection
166
+
</entry>
167
+
</row>
168
+
<row>
169
+
<entry valign="top">
170
+
<constant>CURLINFO_LOCAL_PORT</constant>
171
+
</entry>
172
+
<entry valign="top">
173
+
Local (source) port of the most recent connection
174
+
</entry>
175
+
</row>
176
+
<row>
177
+
<entry valign="top">
178
+
<constant>CURLINFO_SIZE_UPLOAD</constant>
179
+
</entry>
180
+
<entry valign="top">
181
+
Total number of bytes uploaded
182
+
</entry>
183
+
</row>
184
+
<row>
185
+
<entry valign="top">
186
+
<constant>CURLINFO_SIZE_DOWNLOAD</constant>
187
+
</entry>
188
+
<entry valign="top">
189
+
Total number of bytes downloaded
190
+
</entry>
191
+
</row>
192
+
<row>
193
+
<entry valign="top">
194
+
<constant>CURLINFO_SPEED_DOWNLOAD</constant>
195
+
</entry>
196
+
<entry valign="top">
197
+
Average download speed
198
+
</entry>
199
+
</row>
200
+
<row>
201
+
<entry valign="top">
202
+
<constant>CURLINFO_SPEED_UPLOAD</constant>
203
+
</entry>
204
+
<entry valign="top">
205
+
Average upload speed
206
+
</entry>
207
+
</row>
208
+
<row>
209
+
<entry valign="top">
210
+
<constant>CURLINFO_HEADER_SIZE</constant>
211
+
</entry>
212
+
<entry valign="top">
213
+
Total size of all headers received
214
+
</entry>
215
+
</row>
216
+
<row>
217
+
<entry valign="top">
218
+
<constant>CURLINFO_HEADER_OUT</constant>
219
+
</entry>
220
+
<entry valign="top">
221
+
The request string sent. For this to work, add the CURLINFO_HEADER_OUT option to the handle by calling curl_setopt()
222
+
</entry>
223
+
</row>
224
+
<row>
225
+
<entry valign="top">
226
+
<constant>CURLINFO_REFERER</constant>
227
+
</entry>
228
+
<entry valign="top">
229
+
The referrer header
230
+
</entry>
231
+
</row>
232
+
<row>
233
+
<entry valign="top">
234
+
<constant>CURLINFO_REQUEST_SIZE</constant>
235
+
</entry>
236
+
<entry valign="top">
237
+
Total size of issued requests, currently only for HTTP requests
238
+
</entry>
239
+
</row>
240
+
<row>
241
+
<entry valign="top">
242
+
<constant>CURLINFO_RETRY_AFTER</constant>
243
+
</entry>
244
+
<entry valign="top">
245
+
The information from the Retry-After: header, or zero if there was no valid header.
246
+
</entry>
247
+
</row>
248
+
<row>
249
+
<entry valign="top">
250
+
<constant>CURLINFO_SSL_VERIFYRESULT</constant>
251
+
</entry>
252
+
<entry valign="top">
253
+
Result of SSL certification verification requested by setting CURLOPT_SSL_VERIFYPEER
254
+
</entry>
255
+
</row>
256
+
<row>
257
+
<entry valign="top">
258
+
<constant>CURLINFO_CONTENT_LENGTH_DOWNLOAD</constant>
259
+
</entry>
260
+
<entry valign="top">
261
+
Content length of download, read from Content-Length: field
262
+
</entry>
263
+
</row>
264
+
<row>
265
+
<entry valign="top">
266
+
<constant>CURLINFO_CONTENT_LENGTH_UPLOAD</constant>
267
+
</entry>
268
+
<entry valign="top">
269
+
Specified size of upload
270
+
</entry>
271
+
</row>
272
+
<row>
273
+
<entry valign="top">
274
+
<constant>CURLINFO_CONTENT_TYPE</constant>
275
+
</entry>
276
+
<entry valign="top">
277
+
Content-Type: of the requested document. NULL indicates server did not send valid Content-Type: header
278
+
</entry>
279
+
</row>
280
+
<row>
281
+
<entry valign="top">
282
+
<constant>CURLINFO_PRIVATE</constant>
283
+
</entry>
284
+
<entry valign="top">
285
+
Private data associated with this cURL handle, previously set with the CURLOPT_PRIVATE option of curl_setopt()
286
+
</entry>
287
+
</row>
288
+
<row>
289
+
<entry valign="top">
290
+
<constant>CURLINFO_PROXY_ERROR</constant>
291
+
</entry>
292
+
<entry valign="top">
293
+
The detailed (SOCKS) proxy error code when the most recent transfer returned a CURLE_PROXY error. The returned value will be exactly one of the CURLPX_* values. The error code will be CURLPX_OK if no response code was available.
294
+
</entry>
295
+
</row>
296
+
<row>
297
+
<entry valign="top">
298
+
<constant>CURLINFO_RESPONSE_CODE</constant>
299
+
</entry>
300
+
<entry valign="top">
301
+
The last response code
302
+
</entry>
303
+
</row>
304
+
<row>
305
+
<entry valign="top">
306
+
<constant>CURLINFO_HTTP_CONNECTCODE</constant>
307
+
</entry>
308
+
<entry valign="top">
309
+
The CONNECT response code
310
+
</entry>
311
+
</row>
312
+
<row>
313
+
<entry valign="top">
314
+
<constant>CURLINFO_HTTPAUTH_AVAIL</constant>
315
+
</entry>
316
+
<entry valign="top">
317
+
Bitmask indicating the authentication method(s) available according to the previous response
318
+
</entry>
319
+
</row>
320
+
<row>
321
+
<entry valign="top">
322
+
<constant>CURLINFO_PROXYAUTH_AVAIL</constant>
323
+
</entry>
324
+
<entry valign="top">
325
+
Bitmask indicating the proxy authentication method(s) available according to the previous response
326
+
</entry>
327
+
</row>
328
+
<row>
329
+
<entry valign="top">
330
+
<constant>CURLINFO_OS_ERRNO</constant>
331
+
</entry>
332
+
<entry valign="top">
333
+
Errno from a connect failure. The number is OS and system specific.
334
+
</entry>
335
+
</row>
336
+
<row>
337
+
<entry valign="top">
338
+
<constant>CURLINFO_NUM_CONNECTS</constant>
339
+
</entry>
340
+
<entry valign="top">
341
+
Number of connections curl had to create to achieve the previous transfer
342
+
</entry>
343
+
</row>
344
+
<row>
345
+
<entry valign="top">
346
+
<constant>CURLINFO_SSL_ENGINES</constant>
347
+
</entry>
348
+
<entry valign="top">
349
+
OpenSSL crypto-engines supported
350
+
</entry>
351
+
</row>
352
+
<row>
353
+
<entry valign="top">
354
+
<constant>CURLINFO_COOKIELIST</constant>
355
+
</entry>
356
+
<entry valign="top">
357
+
All known cookies
358
+
</entry>
359
+
</row>
360
+
<row>
361
+
<entry valign="top">
362
+
<constant>CURLINFO_FTP_ENTRY_PATH</constant>
363
+
</entry>
364
+
<entry valign="top">
365
+
Entry path in FTP server
366
+
</entry>
367
+
</row>
368
+
<row>
369
+
<entry valign="top">
370
+
<constant>CURLINFO_APPCONNECT_TIME</constant>
371
+
</entry>
372
+
<entry valign="top">
373
+
Time in seconds it took from the start until the SSL/SSH connect/handshake to the remote host was completed
374
+
</entry>
375
+
</row>
376
+
<row>
377
+
<entry valign="top">
378
+
<constant>CURLINFO_CERTINFO</constant>
379
+
</entry>
380
+
<entry valign="top">
381
+
TLS certificate chain
382
+
</entry>
383
+
</row>
384
+
<row>
385
+
<entry valign="top">
386
+
<constant>CURLINFO_CONDITION_UNMET</constant>
387
+
</entry>
388
+
<entry valign="top">
389
+
Info on unmet time conditional
390
+
</entry>
391
+
</row>
392
+
<row>
393
+
<entry valign="top">
394
+
<constant>CURLINFO_RTSP_CLIENT_CSEQ</constant>
395
+
</entry>
396
+
<entry valign="top">
397
+
Next RTSP client CSeq
398
+
</entry>
399
+
</row>
400
+
<row>
401
+
<entry valign="top">
402
+
<constant>CURLINFO_RTSP_CSEQ_RECV</constant>
403
+
</entry>
404
+
<entry valign="top">
405
+
Recently received CSeq
406
+
</entry>
407
+
</row>
408
+
<row>
409
+
<entry valign="top">
410
+
<constant>CURLINFO_RTSP_SERVER_CSEQ</constant>
411
+
</entry>
412
+
<entry valign="top">
413
+
Next RTSP server CSeq
414
+
</entry>
415
+
</row>
416
+
<row>
417
+
<entry valign="top">
418
+
<constant>CURLINFO_RTSP_SESSION_ID</constant>
419
+
</entry>
420
+
<entry valign="top">
421
+
RTSP session ID
422
+
</entry>
423
+
</row>
424
+
<row>
425
+
<entry valign="top">
426
+
<constant>CURLINFO_CONTENT_LENGTH_DOWNLOAD_T</constant>
427
+
</entry>
428
+
<entry valign="top">
429
+
The content-length of the download. This is the value read from the Content-Length: field. -1 if the size isn't known
430
+
</entry>
431
+
</row>
432
+
<row>
433
+
<entry valign="top">
434
+
<constant>CURLINFO_CONTENT_LENGTH_UPLOAD_T</constant>
435
+
</entry>
436
+
<entry valign="top">
437
+
The specified size of the upload. -1 if the size isn't known
438
+
</entry>
439
+
</row>
440
+
<row>
441
+
<entry valign="top">
442
+
<constant>CURLINFO_HTTP_VERSION</constant>
443
+
</entry>
444
+
<entry valign="top">
445
+
The version used in the last HTTP connection. The return value will be one of the defined CURL_HTTP_VERSION_* constants or 0 if the version can't be determined
446
+
</entry>
447
+
</row>
448
+
<row>
449
+
<entry valign="top">
450
+
<constant>CURLINFO_PROTOCOL</constant>
451
+
</entry>
452
+
<entry valign="top">
453
+
The protocol used in the last HTTP connection. The returned value will be exactly one of the CURLPROTO_* values
454
+
</entry>
455
+
</row>
456
+
<row>
457
+
<entry valign="top">
458
+
<constant>CURLINFO_PROXY_SSL_VERIFYRESULT</constant>
459
+
</entry>
460
+
<entry valign="top">
461
+
The result of the certificate verification that was requested (using the CURLOPT_PROXY_SSL_VERIFYPEER option). Only used for HTTPS proxies
462
+
</entry>
463
+
</row>
464
+
<row>
465
+
<entry valign="top">
466
+
<constant>CURLINFO_SCHEME</constant>
467
+
</entry>
468
+
<entry valign="top">
469
+
The URL scheme used for the most recent connection
470
+
</entry>
471
+
</row>
472
+
<row>
473
+
<entry valign="top">
474
+
<constant>CURLINFO_SIZE_DOWNLOAD_T</constant>
475
+
</entry>
476
+
<entry valign="top">
477
+
Total number of bytes that were downloaded. The number is only for the latest transfer and will be reset again for each new transfer
478
+
</entry>
479
+
</row>
480
+
<row>
481
+
<entry valign="top">
482
+
<constant>CURLINFO_SIZE_UPLOAD_T</constant>
483
+
</entry>
484
+
<entry valign="top">
485
+
Total number of bytes that were uploaded
486
+
</entry>
487
+
</row>
488
+
<row>
489
+
<entry valign="top">
490
+
<constant>CURLINFO_SPEED_DOWNLOAD_T</constant>
491
+
</entry>
492
+
<entry valign="top">
493
+
The average download speed in bytes/second that curl measured for the complete download
494
+
</entry>
495
+
</row>
496
+
<row>
497
+
<entry valign="top">
498
+
<constant>CURLINFO_SPEED_UPLOAD_T</constant>
499
+
</entry>
500
+
<entry valign="top">
501
+
The average upload speed in bytes/second that curl measured for the complete upload
502
+
</entry>
503
+
</row>
504
+
<row>
505
+
<entry valign="top">
506
+
<constant>CURLINFO_APPCONNECT_TIME_T</constant>
507
+
</entry>
508
+
<entry valign="top">
509
+
Time, in microseconds, it took from the start until the SSL/SSH connect/handshake to the remote host was completed
510
+
</entry>
511
+
</row>
512
+
<row>
513
+
<entry valign="top">
514
+
<constant>CURLINFO_CONNECT_TIME_T</constant>
515
+
</entry>
516
+
<entry valign="top">
517
+
Total time taken, in microseconds, from the start until the connection to the remote host (or proxy) was completed
518
+
</entry>
519
+
</row>
520
+
<row>
521
+
<entry valign="top">
522
+
<constant>CURLINFO_FILETIME_T</constant>
523
+
</entry>
524
+
<entry valign="top">
525
+
Remote time of the retrieved document (as Unix timestamp), an alternative to CURLINFO_FILETIME to allow systems with 32 bit long variables to extract dates outside of the 32bit timestamp range
526
+
</entry>
527
+
</row>
528
+
<row>
529
+
<entry valign="top">
530
+
<constant>CURLINFO_NAMELOOKUP_TIME_T</constant>
531
+
</entry>
532
+
<entry valign="top">
533
+
Time in microseconds from the start until the name resolving was completed
534
+
</entry>
535
+
</row>
536
+
<row>
537
+
<entry valign="top">
538
+
<constant>CURLINFO_PRETRANSFER_TIME_T</constant>
539
+
</entry>
540
+
<entry valign="top">
541
+
Time taken from the start until the file transfer is just about to begin, in microseconds
542
+
</entry>
543
+
</row>
544
+
<row>
545
+
<entry valign="top">
546
+
<constant>CURLINFO_REDIRECT_TIME_T</constant>
547
+
</entry>
548
+
<entry valign="top">
549
+
Total time, in microseconds, it took for all redirection steps include name lookup, connect, pretransfer and transfer before final transaction was started
550
+
</entry>
551
+
</row>
552
+
<row>
553
+
<entry valign="top">
554
+
<constant>CURLINFO_STARTTRANSFER_TIME_T</constant>
555
+
</entry>
556
+
<entry valign="top">
557
+
Time, in microseconds, it took from the start until the first byte is received
558
+
</entry>
559
+
</row>
560
+
<row>
561
+
<entry valign="top">
562
+
<constant>CURLINFO_TOTAL_TIME_T</constant>
563
+
</entry>
564
+
<entry valign="top">
565
+
Total time in microseconds for the previous transfer, including name resolving, TCP connect etc.
566
+
</entry>
567
+
</row>
568
+
</tbody>
569
+
</tgroup>
570
+
</informaltable>
342
571
</para>
343
572
</listitem>
344
573
</varlistentry>
...
...
@@ -349,9 +578,9 @@
349
578
<refsect1 role="returnvalues">
350
579
&reftitle.returnvalues;
351
580
<para>
352
-
If <parameter>opt</parameter> is given, returns its value.
581
+
If <parameter>option</parameter> is given, returns its value.
353
582
Otherwise, returns an associative array with the following elements
354
-
(which correspond to <parameter>opt</parameter>), or &false; on failure:
583
+
(which correspond to <parameter>option</parameter>), or &false; on failure:
355
584
<itemizedlist>
356
585
<listitem>
357
586
<simpara>
...
...
@@ -507,6 +736,29 @@
507
736
</thead>
508
737
<tbody>
509
738
<row>
739
+
<entry>8.3.0</entry>
740
+
<entry>
741
+
Introduced <constant>CURLINFO_CAINFO</constant>
742
+
and <constant>CURLINFO_CAPATH</constant>.
743
+
</entry>
744
+
</row>
745
+
<row>
746
+
<entry>8.2.0</entry>
747
+
<entry>
748
+
Introduced <constant>CURLINFO_PROXY_ERROR</constant>,
749
+
<constant>CURLINFO_REFERER</constant>,
750
+
<constant>CURLINFO_RETRY_AFTER</constant>.
751
+
</entry>
752
+
</row>
753
+
&curl.changelog.handle-param;
754
+
<row>
755
+
<entry>8.0.0</entry>
756
+
<entry>
757
+
<parameter>option</parameter> is nullable now;
758
+
previously, the default was <literal>0</literal>.
759
+
</entry>
760
+
</row>
761
+
<row>
510
762
<entry>7.3.0</entry>
511
763
<entry>
512
764
Introduced <constant>CURLINFO_CONTENT_LENGTH_DOWNLOAD_T</constant>,
...
...
@@ -529,59 +781,6 @@
529
781
<constant>CURLINFO_TOTAL_TIME_T</constant>.
530
782
</entry>
531
783
</row>
532
-
<row>
533
-
<entry>5.5.0</entry>
534
-
<entry>
535
-
Introduced <constant>CURLINFO_RESPONSE_CODE</constant>,
536
-
<constant>CURLINFO_HTTP_CONNECTCODE</constant>,
537
-
<constant>CURLINFO_HTTPAUTH_AVAIL</constant>,
538
-
<constant>CURLINFO_PROXYAUTH_AVAIL</constant>,
539
-
<constant>CURLINFO_OS_ERRNO</constant>,
540
-
<constant>CURLINFO_NUM_CONNECTS</constant>,
541
-
<constant>CURLINFO_SSL_ENGINES</constant>,
542
-
<constant>CURLINFO_COOKIELIST</constant>,
543
-
<constant>CURLINFO_FTP_ENTRY_PATH</constant>,
544
-
<constant>CURLINFO_APPCONNECT_TIME</constant>,
545
-
<constant>CURLINFO_CONDITION_UNMET</constant>,
546
-
<constant>CURLINFO_RTSP_CLIENT_CSEQ</constant>,
547
-
<constant>CURLINFO_RTSP_CSEQ_RECV</constant>,
548
-
<constant>CURLINFO_RTSP_SERVER_CSEQ</constant> and
549
-
<constant>CURLINFO_RTSP_SESSION_ID</constant>.
550
-
</entry>
551
-
</row>
552
-
<row>
553
-
<entry>5.4.7</entry>
554
-
<entry>
555
-
Introduced <constant>CURLINFO_PRIMARY_IP</constant>,
556
-
<constant>CURLINFO_PRIMARY_PORT</constant>,
557
-
<constant>CURLINFO_LOCAL_IP</constant> and
558
-
<constant>CURLINFO_LOCAL_PORT</constant>.
559
-
</entry>
560
-
</row>
561
-
<row>
562
-
<entry>5.3.7</entry>
563
-
<entry>
564
-
Introduced <constant>CURLINFO_REDIRECT_URL</constant>.
565
-
</entry>
566
-
</row>
567
-
<row>
568
-
<entry>5.3.0</entry>
569
-
<entry>
570
-
Introduced <constant>CURLINFO_CERTINFO</constant>.
571
-
</entry>
572
-
</row>
573
-
<row>
574
-
<entry>5.2.4</entry>
575
-
<entry>
576
-
Introduced <constant>CURLINFO_PRIVATE</constant>.
577
-
</entry>
578
-
</row>
579
-
<row>
580
-
<entry>5.1.3</entry>
581
-
<entry>
582
-
Introduced <constant>CURLINFO_HEADER_OUT</constant>.
583
-
</entry>
584
-
</row>
585
784
</tbody>
586
785
</tgroup>
587
786
</informaltable>
...
...
@@ -617,7 +816,7 @@ curl_close($ch);
617
816
</para>
618
817
<para>
619
818
<example>
620
-
<title><function>curl_getinfo</function> example with <parameter>opt</parameter> parameter</title>
819
+
<title><function>curl_getinfo</function> example with <parameter>option</parameter> parameter</title>
621
820
<programlisting role="php">
622
821
<![CDATA[
623
822
<?php
...
...
@@ -657,7 +856,6 @@ curl_close($ch);
657
856
</note>
658
857
</refsect1>
659
858
</refentry>
660
-

661
859
<!-- Keep this comment at the end of the file
662
860
Local variables:
663
861
mode: sgml
664
862