I want to have a hyperlink file download on hypertext in an html5
document. I want to link the tag to some vanilla javascript,
probably my ajax and XMLHttpRequest. I want to use the javascript
to examine the file download as it leaves the browser and goes to the download
client directory. I want to be able to display percentage completed,
bytes, kilobytes or Megabytes completed, at the instant the file download progress,
and to instantly update , irrespective of any length setting(s) on the progress bar.
I have not been able to debug my own javascript code, or any volunteer code from the internet, particularly code that does NOT use php or JQuery.
Can someone please respond with some vanilla javascript that runs correctly, in relation to my code fragment included down here, kindly, please?
<!-- from Arthurq Dent -->
<a id="fileLink" href="superman.png"> <!-- download="superman.png" -->
Download Superman Logo</a>.
<progress id="progress" value="0"></progress>
<script>
</script>