Added callback parameter to download
Modified as suggested.  download() now only displays progress as output
and can be silenced.
changed download chunksize to 16kb (was 1kb)
clearer variable names in javascript parsing functions
Merge with upstream