Dropzone image upload options not working :(

前端 未结 3 2086
执念已碎
执念已碎 2020-12-15 13:21

Im trying to build a drag and drop image upload but dropzone options dont work and I dont know if im doing it the right way.

I would love to set up the following opt

3条回答
  •  半阙折子戏
    2020-12-15 13:39

    maxFilesize: 2,
    uploadMultiple: false,
    addRemoveLinks: true,
    maxFiles: 1,
    autoProcessQueue: false
    

    You will need to add in a button or event handler to allow for processing of the previewed file, if you let it autoProcessQueue you don't have time to decide if you want the file or not unless you add an event handler at the "process" event.

    $("#uploadme").dropzone.processQueue()
    

提交回复
热议问题