It'll be surprisingly fiddly to get an accurate number. I think your best bet is to use JS and make a plain http get for a file of known size and time that and disable caching. Off the top of my head, something like :
img.src = 'http://yourdomain.com/test.png?' + Math.random();
start = Date.now();
return $(img).load(function ()
{
end = Date.now();
// whatever
});
Not entirely sure that'll work - but there go. I think jquery's ajax calls have an option to disable caching too.
You still won't get a very consistent or reliable number though - if someone is downloading something else at the time for instance, then your number will be totally different.