Is there anyway to see how long a simple $.getJSON method takes to call using some type of timing code, in jquery/javascript?
Secondly, is there any way to see how BIG the response Content-Length is, in kB or megabytes?
Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.
Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.
Lost your password? Please enter your email address. You will receive a link and will create a new password via email.
Please briefly explain why you feel this question should be reported.
Please briefly explain why you feel this answer should be reported.
Please briefly explain why you feel this user should be reported.
If you want pure javascript, right before you send the request note the time using
new Date().getTime();Then in the ajax callback, note the time again, and subtract against the first time. That will give you the length of the call.
Something like this: