Upload file from client machine to server - prepopulate file picker path?

Posted by user246114 on Stack Overflow See other posts from Stack Overflow or by user246114
Published on 2010-04-03T15:54:32Z Indexed on 2010/04/03 18:03 UTC
Read the original article Hit count: 145

Filed under:

Hi,

I'd like to upload a file from a client machine to my server. The user would have to specify the file to upload as I understand it, using a form that looks like:

<input type="file" name="datafile" size="40">

This pops up a native file picker, which is great. The problem I'm having is that it's a real pain (for most users) to go looking around their machine for the file I'm interested in. Is there a way I can initialize the file picker with a path to make it more convenient for the user? Like I know some users will be on a windows machine, so I could prepopulate the picker by already sending them to the My Documents folder for example.

I don't see how this is possible, just wondering if something like that exists,

Thank you

© Stack Overflow or respective owner

Related posts about JavaScript