fixes #70
This commit is contained in:
parent
03cbedb255
commit
7393c06302
|
@ -3972,16 +3972,13 @@ $('body').on('click','.upload-cover-photo, .upload-avatar, .upload-background-im
|
||||||
coverPhotoAndAvatarSelectAndCrop(e, coverOrAvatar);
|
coverPhotoAndAvatarSelectAndCrop(e, coverOrAvatar);
|
||||||
})});
|
})});
|
||||||
|
|
||||||
// trigger click for firefox
|
// trigger click
|
||||||
if(navigator.userAgent.toLowerCase().indexOf('firefox') > -1) {
|
$('#' + inputId).trigger('click');
|
||||||
$('#' + inputId).trigger('click');
|
// chrome, opera and safari now supports above method,
|
||||||
}
|
// before we had use the method below for those.
|
||||||
// other browsers
|
// var evt = document.createEvent("HTMLEvents");
|
||||||
else {
|
// evt.initEvent("click", true, true);
|
||||||
var evt = document.createEvent("HTMLEvents");
|
// $('#' + inputId)[0].dispatchEvent(evt);
|
||||||
evt.initEvent("click", true, true);
|
|
||||||
$('#' + inputId)[0].dispatchEvent(evt);
|
|
||||||
}
|
|
||||||
|
|
||||||
});
|
});
|
||||||
|
|
||||||
|
@ -4110,16 +4107,14 @@ $('body').on('click','.upload-image',function () {
|
||||||
})
|
})
|
||||||
});
|
});
|
||||||
|
|
||||||
// trigger click for firefox
|
// trigger click
|
||||||
if(navigator.userAgent.toLowerCase().indexOf('firefox') > -1) {
|
$('#upload-image-input').trigger('click');
|
||||||
$('#upload-image-input').trigger('click');
|
// chrome, opera and safari now supports above method,
|
||||||
}
|
// before we had use the method below for those.
|
||||||
// other browsers
|
// var evt = document.createEvent("HTMLEvents");
|
||||||
else {
|
// evt.initEvent("click", true, true);
|
||||||
var evt = document.createEvent("HTMLEvents");
|
// $('#upload-image-input')[0].dispatchEvent(evt);
|
||||||
evt.initEvent("click", true, true);
|
|
||||||
$('#upload-image-input')[0].dispatchEvent(evt);
|
|
||||||
}
|
|
||||||
});
|
});
|
||||||
|
|
||||||
function uploadAttachment(e, thisUploadButton) {
|
function uploadAttachment(e, thisUploadButton) {
|
||||||
|
|
Loading…
Reference in New Issue
Block a user