Today I worked on a strange issue where JQuery.Multifile was not working in other browsers than IE or FF. More exactly, it was not working on Opera 10.01, Google Chrome 3.0 and Safari. After googling and testing alot I was about to give up, especially when I saw this link: http://code.google.com/p/jquery-multifile-plugin/issues/detail?id=37

Still I was not ready to give up and dug deeper into the code until it hit me. The problem is related to the “name” property of the input tag. If you don’t specify it, in some browsers the files will not be sent along with the request.

Thus we have:
Bad way : <input type=”file” class=”multi” id=”fileControl”/> Works in IE and FF
Good way : <input type=”file” class=”multi” id=”fileControl” name=”fileControl”/> Works in IE, FF, Chrome, Opera, Safari and probably others (if they are based on WebKIT)

Cheers

Leave a Reply