Integrating Dropzone.Js into Existing HTML Form with Other Fields

Can't implement dropzone.js to an existing form

I had to add 'done' to the accept function:

accept: function(file, done) {
.
.
done();
}

How do I put dropzone.js box to an existing form in my html file?

Dropzone is a very extensible library. it allows use to make any div a dropzone.
If you don't want to use form - you can make a dropzone programatically using -

var myDropzone = new Dropzone("div#myId", { url: "/file/post"});

if you are using native javascript. And if you are using jquery you can use -

$("div#myId").dropzone({ url: "/file/post" });


Related Topics



Leave a reply



Submit