2

Is there a way to download file and a way to 'track' that download progress and see if download is completed/successful or if it was canceled?

I'm in a position where I should update a state of the file in db upon successful download and I find it very hard to acquire the best way on how to accomplish that.

Over past few days I've been all over the stackoverflow and found very interesting answers, like:

What is then the right approach/technology/... to detect successful download and update a db table?

Community
  • 1
  • 1
Sylca
  • 2,523
  • 4
  • 31
  • 51
  • 1
    Relevant: http://stackoverflow.com/questions/1106377/detect-when-browser-receives-file-download – ʰᵈˑ Jun 03 '15 at 08:45
  • @ʰᵈˑ thanks. I think this will be of a great help! – Sylca Jun 03 '15 at 08:49
  • 3
    The bigger question is: what would this tell you and isn't there a better way to handle that? Even if you can detect when the browser has technically successfully received all the data you sent it... there's still a million ways how that data did **not** end up saved as a file on the user's hard disk. – deceze Jun 03 '15 at 08:52
  • @deceze I agree! I'll have to come up with a way to handle that as well :-) – Sylca Jun 03 '15 at 09:09
  • So you probably want an entirely different solution to begin with... what are you tracking that download for? How critical is it that this be 100% reliable? Why is it so critical, what purpose are you doing this for in the grant scheme of things? – deceze Jun 03 '15 at 09:12
  • Yes, I probably need to start from the scratch. The thing is that I track file statuses from upload to finalization, I list the files that are for download and after successful download the files should leave that list. I think that it's not that critical since I can come up with some way to handle 'broken downloads'. – Sylca Jun 03 '15 at 09:32

0 Answers0