Upload Contents Of An Entire Folder Using Plupload
I have created a custom uploader using Plupload's core api and it works well but one feature I would like to add is how to upload the contents of a folder when it is dragged onto t
Solution 1:
This isn't possible, unless the user is using chrome.
Solution 2:
The minimal line to ensure you are compatible with most browsers is:
<inputtype="file" directory="" webkitdirectory="" mozdirectory="" />
So, we know that Chrome, browsers with WebKit and Firefox are compatible with the 'directory' parameters. Then you're better to give it a style, because it will appear as "Choose files".
Most websites are using the 'fakefile' approach:
div.fileinputs
{
position: relative;
}
div.fakefile
{
position: absolute;
top: 0px;
left: 0px;
z-index: 1;
}
input.file {
position: relative;
text-align: right;
-moz-opacity:0 ;
filter:alpha(opacity: 0);
opacity: 0;
z-index: 2;
}
<divclass="fileinputs"><inputtype="file"class="file" /><divclass="fakefile"><input /><imgsrc="search.gif" /></div></div>
I know the post is old, but nowadays, we often sync our folders with some cloud on the web, so the file by file method is less used.
Post a Comment for "Upload Contents Of An Entire Folder Using Plupload"