Dropzone can get a little confused:
First you should get a file management system for Meteor. The standard now is CollectionFS:
https://github.com/CollectionFS/Meteor-CollectionFS
Then you need to add the file system. I use GridFS, which breaks large files into pieces and stores them for you in Mongo:
https://github.com/CollectionFS/Meteor-cfs-gridfs/
Follow the instructions to create, publish, and subscribe to the new FS special collection:
example for creating the collection: MyImages = new FS.Collection('myImages', { stores: [new FS.Store.GridFS("myImages")] });
After these two are installed, create your dropzone:
<template name="imageUpload"> <form action="/file-upload" class="dropzone" id="dropzone"></form> </template>
Then in your javascript:
Template.imageUpload.rendered = function(){ if (Meteor.isClient){ var arrayOfImageIds = []; Dropzone.autoDiscover = false;
source share