I am using jQuery file upload to upload files in IE8. As this is an old non-HTML5 friendly browser, I am using jQuery Iframe Transport Plugin 1.8.2.
The 'done' is not being called and Iframe content appears empty.
CODE:
$('#files').fileupload({
dataType: 'json',
url: "/FileUploads/Upload",
type: 'PUT',
forceIframeTransport: true,
progressall: function (e, data) {
var progress = parseInt(data.loaded / data.total * 100, 10);
$('#progress .bar').css(
'width',
progress + '%'
);
},
add: function (e, data) {
data.context = $('<button/>').text('Upload')
.appendTo($('#FileUploadsDrop'))
.click(function () {
data.context = $('<p/>').text('Uploading...'+$('#files').val()).replaceAll($(this));
data.submit();
});
},
done: function ( e, data ) {
var result = $( 'pre', data.result ).text();
if(result != null && $.trim( result ) != '' ){
$('#FileUploadsDrop').append( result );
}
}
});`
Here is the DOM situation: