views:

61

answers:

5

Over the last couple of days I've been looking for a way to upload the contents of a directory to a server via a web client. Pretty much all the file upload solutions I've seen restrict the user to selecting one file a time via a browse button.

What's the { best | easiest | most popular } way to do this?

I'm using ASP.NET MVC on the server side, and jQuery on the client side. I wouldn't dismiss a flash/silverlight solution although I'd prefer not to go down that road if it wasn't necessary.

A: 

Basically with straight HTML forms, you can't. Its not how browsers are written and its locked down for security. I don't think Flash/Silverlight will let you do that either, again for security. I know in Flash a user can select multiple files. I also know Air can do see folders.

Daniel A. White
+1  A: 

As Daniel said, not doable.

As a workaround, you could instruct users to upload a .zip of the folder.

JMP
A: 

We use signed applets to solve the same problem since uploading zip files is considered to be "too tough" for the users!!

Vijay Dev
+1  A: 

You can upload multiple files using a flash uploader such as SWFupload. JQuery forms also does something like this but I haven't tested it out.

marcgg
A: 

As far as I'm aware, you could use a Java Applet for this purpose - I imagine you would have to sign it to allow it access to the file system. Not everyone has Java installed either, but it's a workable solution.

Tom Woolfrey