Reputation: 149
Could anybody let me know, if I understand the curl_getinfo() information right?
Array
(
[url] => https://www.someserver.com
[content_type] => text/html
[http_code] => 200
[header_size] => 350
[filetime] => -1
[ssl_verify_result] => 19
[redirect_count] => 0
[total_time] => 0.078
[namelookup_time] => 0
[connect_time] => 0.016
[pretransfer_time] => 0.031
[starttransfer_time] => 0.078
[redirect_time] => 0
)
As I understand pretransfer_time
means the time, when the headers request is already sent to the server and server is executing request? Then the starttransfer_time
should mean the time, when the page is prepared by the server, and the client starts to receive data (headers+body?). Am I right?
Upvotes: 4
Views: 2989
Reputation: 4820
About pretransfer_time
, sure. starttransfer_time
- when the client starts to receive data, but not server load time. There's no way to know unless it is configurated to send that info somehow.
Upvotes: 2
Reputation: 3573
Pass a pointer to a double to receive the time, in seconds, it took from the start until the file transfer is just about to begin. This includes all pre-transfer commands and negotiations that are specific to the particular protocol(s) involved
Pass a pointer to a double to receive the time, in seconds, it took from the start until the first byte is just about to be transferred. This includes CURLINFO_PRETRANSFER_TIME and also the time the server needs to calculate the result
Upvotes: 2