Dropzone.js Drag & Drop not working in IE10

I followed the textbook. Combine the regular form with Dropzone ( https://github.com/enyo/dropzone/wiki/Combine-normal-form-with-Dropzone ), and the resulting page works fine in the latest version of Google Chrome.

But, when I test the same page in IE10, drag and drop does not work. The drag and drop zone is clickable and I can upload files to the server, so dropzone will be initialized correctly. This is just a drag and drop function that doesn't work.

When I try the demo at http://www.dropzonejs.com/ , drag and drop works in IE10.

I checked IE Internet browser settings and everything is included, and also added localhost to trusted sites.

This is my code:

<script src="~/Scripts/dropzone.js"></script>
<script type="text/javascript">
    Dropzone.options.dropzoneForm = {
        autoProcessQueue: false,
        uploadMultiple: true,
        parallelUploads: 100,
        maxFiles: 100,
        addRemoveLinks: true,
        createImageThumbnails: false,

        // The setting up of the dropzone
        init: function() {
            var myDropzone = this;

            // First change the button to actually tell Dropzone to process the queue.
            this.element.querySelector("button[type=submit]").addEventListener("click", function(e) {
                // Make sure that the form isn't actually being sent.
                e.preventDefault();
                e.stopPropagation();
                myDropzone.processQueue();
            });
        }
    };
</script>

<form action="~/FileUpload/SaveUploadedFiles" method="post" enctype="multipart/form-data" class="dropzone" id="dropzoneForm">
    <div class="dropzone-previews"></div>
    <button type="submit">Submit data and files!</button>
</form>

, .

- ?

+4
3

bundleconfig

        // dropZone styles
        bundles.Add(new StyleBundle("~/Scripts/dropZone").Include(
                  "~/Scripts/dropzone/css/basic.css",
                  "~/Scripts/dropzone/css/dropzone.css"));

        // dropZone 
        bundles.Add(new ScriptBundle("~/Scripts/dropzone").Include(
                  "~/Scripts/dropzone/dropzone.js"));

script, : (SOS) - css , js , .

+1

Check the header section to make sure you force compatibility with the old version of IE. The developer set our IE = 9 and caused 500 internal server errors each time the file was uploaded to IE11.

0
source

All Articles