I'm having an issue with dropzone.js where it reports this issue when uploading many "big" files (by big I mean 3-5MB each)
Uncaught Error: No Dropzone found for given element. This is probably because you're trying to access it before Dropzone had the time to initialize. Use the
init
option to setup any additional observers on your Dropzone
Everything works fine with uploading small files (100-300kbs)
Does anybody know what's happening here?
答案 0 :(得分:0)
您可能忘记给dropzone一个ID。
您可以通过以下方式使用该组件。
{{drop-zone url='http://localhost/dummy' addfilehere=(action "addfilehere")
id="uniqueID" addRemoveLinks=true autoProcessQueue=false}}
在您使用dropzone的组件中,您可以添加以下对ID的引用
this.set('dropzone', Dropzone.forElement('#uniqueID'));