| @@ -265,16 +265,17 @@ function upload_read_event(e) { | |||
| processData: false, | |||
| xhr: function() | |||
| { | |||
| var xhr = new window.XMLHttpRequest(); | |||
| xhr.upload['data'] = e.data; | |||
| xhr.upload.addEventListener("progress", function(evt){ | |||
| var xhr = $.ajaxSettings.xhr(); | |||
| $(xhr.upload).on('progress', e.data, function(evt) { | |||
| // xhr.upload.addEventListener("progress", function(evt){ | |||
| if (evt.lengthComputable) { | |||
| var progress = Math.floor(evt.loaded / evt.total * 50); | |||
| if ( progress < 1 ) { progress = 1; } | |||
| if ( progress > 49 ) { progress = 49; } | |||
| console.log("upload_progress_event", evt); | |||
| } | |||
| }, false); | |||
| }); | |||
| //}, false); | |||
| return xhr; | |||
| }, | |||
| success: function(data, status, xhr){ | |||