framework7 icon indicating copy to clipboard operation
framework7 copied to clipboard

ajax xhr track upload progress not working

Open tinyCoder32 opened this issue 9 years ago • 2 comments

Hi, I was using:

xhr: function() {
                var myXhr = $.ajaxSettings.xhr();
                if(myXhr.upload){
                    myXhr.upload.addEventListener('progress',progress, false);
                }

                return myXhr;
        }

to track upload status and update a progress bar, but that's with jQuery $.ajax, but after changing to F7 $$.ajax, it is not working anymore.

am i missing something?

tinyCoder32 avatar Dec 18 '16 00:12 tinyCoder32

It should be:

var xhr = $$.ajax(...);
xhr.addEventListener('progress', progress, false);

nolimits4web avatar Dec 20 '16 11:12 nolimits4web

it is not work either, because the event is not "lengthComputable"

pudjamansyurin avatar Jan 07 '18 16:01 pudjamansyurin