IE: input type="file" multiple

20,286

Solution 1

Uploading multiple files is a specific part of HTML5 that none of the Internet Explorers support.

Solution 2

IE should support multiple according to this doc:

http://msdn.microsoft.com/en-us/library/ie/hh772307(v=vs.85).aspx

But even so, their own example does not work with IE9 for me..

<input type="file" multiple="multiple" onchange="for (var i = 0; i < this.files.length; i++) { document.write(this.files[i].name ) };" />

When the onchange event fires, the files property doesn't appear to exist for the HTMLInputElement in IE, whereas in Chrome it does.

Update: this doc apparently doesn't apply to IE9. IE 10 is said to support the File API. Let's hope it will be released soon.

Solution 3

You may use button that create additional inputs in IE.
It will work same as multiple input in other browsers(for your server).

Sure, users will should select every file one by one, but they use IE

Solution 4

I got it fixed by adding below metadata at the top of page after "Title" tag.

<meta http-equiv="X-UA-Compatible" content="IE=edge" />

"IE=Edge" loads the latest version of IE version.

Share:
20,286
Run
Author by

Run

A cross-disciplinary full-stack web developer/designer.

Updated on July 10, 2022

Comments

  • Run
    Run almost 2 years

    How come IE 9 does not support input type="file" multiple like other browsers do?

    <form action="#" method="post" enctype="multipart/form-data">
      <input type="file" multiple name="uploads[]" />
      <input type="submit"/>
    </form>
    

    How can I make it work on IE?

  • Tien Do
    Tien Do almost 12 years
    Since I cannot upload files by drag-and-drop with IE so I must use classic file input, and then it does not allow me to select multiple files. IE the greatest browser :D.
  • Luca Detomi
    Luca Detomi over 8 years
    This does not provide an answer to the question. To critique or request clarification from an author, leave a comment below their post - you can always comment on your own posts, and once you have sufficient reputation you will be able to comment on any post. - From Review
  • vard
    vard over 8 years
    @LucaDetomi How this doesn't provide an answer to the question?
  • Luca Detomi
    Luca Detomi over 8 years
    Your nswer was flagged as too short and automatic tools highlight this fact. I'm not saying that it's not correct, but I suggest you to add more details to let users "why" your answer is a good one and maybe the best one. Please, explain basis of your answer so users maybe could "extend" it to other use cases