View Single Post
Old 09-04-2012, 07:16 AM   PM User | #9
rnd me
Senior Coder

 
rnd me's Avatar
 
Join Date: Jun 2007
Location: Urbana
Posts: 3,469
Thanks: 9
Thanked 466 Times in 450 Posts
rnd me is a jewel in the roughrnd me is a jewel in the roughrnd me is a jewel in the rough
Quote:
Originally Posted by johnsmith153 View Post
Brilliant. Thanks.

Only thing is:
Code:
new Date;
should be:
Code:
new Date().getTime() / 100;
I've tested and it works great on many occasions and on many different devices.

So much better than the image download scripts I keep seeing.

Thanks again.
my units are KiloBytes per second, you might be looking for KiloBits per second, which is more common in ISP advertising.

i should also mention that you might consider is keeping track of the total time, subtracting delay and the dividing by 5. That math yields your average latency, another quality of service indicator.
__________________
my site (updated 5/13)
STATS (2013/5) HTML5:90.2% MOB:14% IE7:0.5% IE8:8.6% IE9:9.8% IE10:10%
rnd me is offline   Reply With Quote