Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

How does dropbox.com's multiple file upload feature work?

Tags:

html

xhtml

The website frontend for Dropbox allows one to upload multiple files from the same dialogue box.

How does this work exactly? Is it some cutting-edge HTML tag? Or fancy JavaScript? Or a Flash / Java embedded application?

It's amazing and I didn't think it was actually possible!

Please advise.

like image 773
Dougal Avatar asked Sep 08 '26 12:09

Dougal


1 Answers

Last time I checked it was Flash. It uses ActionScripts FileReference class. Check out http://swfupload.org/ if you want to add this kind of functionality to your own application.

What surprised me the most in the beginning was that you could have this kind of functionality with no message asking for user permission whatsoever. I was used to java applets for this kind of feature, and to access the file system they need to be signed, and ask for user permission before execution. The trick with Flash is that you just :

  • open a FileDialog to select files
  • the only thing you can do with the selected files is uploading

So there is no security risk for the user, as the programmer never gets access to the file system.

like image 143
Sébastien Nussbaumer Avatar answered Sep 11 '26 05:09

Sébastien Nussbaumer



Donate For Us

If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!