此脚本无效,因为我每次都在asp.net mvc中运行并上传文件。
它只是陷入了这个功能。
<script type="text/javascript">
window.onload = function () {
Dropzone.options.dzupload = {
addRemoveLinks: true,
success: function (file, response) {
var imgName = response;
file.previewElement.classList.add("dz-success");
console.log("File uploaded")
},
error: function (file, response) {
file.previewElement.classList.add("dz-error");
}
}
};
</script>