Since my previous question wasn't answered, let me put it in a different way.
I would like someone to provide a functional example on how to programatically add a file to plupload queue, ready for uploading.
Perhaps something like this:
$('#uploader').on("ready", function() {
uploader.addFile("c:\\file.jpg");
});
This code isn't working, though.
Thanks.
EDIT: Following Elijah Lynn's answer, I edited my code example to load a file from the server, not from the client.
$('#uploader').on("ready", function() {
uploader.addFile("server_path/file.jpg");
});
This is what worked for me:
You can get more info here https://www.plupload.com/docs/v2/Uploader#addFile-method-filefileName
I do not think you can upload file from your local drive, but you can through a custom drag and drop like you can see here:
https://developer.mozilla.org/en-US/docs/Web/API/HTML_Drag_and_Drop_API/File_drag_and_drop