Is it possible to know (serverside) the time it took for a file to upload? I have an image upload API and in my response I'd like to return the upload time (not including script execution time).
+2
A:
I think yes, there is $_SERVER['REQUEST_TIME']
variable that indicates the start of HTTP request, so on the very beginning of your script:
$upload_time = time() - $_SERVER['REQUEST_TIME'];
Result will be in seconds.
dev-null-dweller
2010-05-28 19:54:40
Thanks, that did the trick!
makeee
2010-05-28 22:44:44