This is mainly for use with the --bytes options since many file managers and applications assume use of 1024 intead of 1000 when it comes to dealing with data sizes in bytes. This is so users can get a closer to realistic view for general data (pretty much except those on OS X and possibly Ubuntu, whose file manager(s) use SI units).
Please see http://en.wikipedia.org/wiki/Binary_prefix
If multiple servers reported the exact same lat. and long. then they
would overwrite eachother in the dict. I changed it to use a
defaultdict so that you could have multiple servers with the exact same
distance. (3 of my closest 5 reported the exact same corrdinates.)
The latency it was printing was not the latency from the chosen best
server. Now it is.
Added a print out of the IP and ISP info.
- Use minidom to replace ElementTree, which is not available in Python 2.5
- Use urllib2.urlopen to replace urllib.urlopen, so we can get HTTP code
- Use cgi.parse_qs when ulrparse.parse_qs is not available