DEV Community

Discussion on: Uploading Files to MongoDB with GridFS and Multer Using NodeJS

Collapse
 
krishnay2000 profile image
Krishnaraj Yadav

Yes I have done that already and even tried to install it globally.Actually, it just works fine if I pass only json data to index.ejs but error occurs only after typing the below code in index.ejs file:

Code link : dev-to-uploads.s3.amazonaws.com/i/...
Error link : dev-to-uploads.s3.amazonaws.com/i/...

Thread Thread
 
shubhambattoo profile image
Shubham Battoo

Can you share your GitHub repo, if you have one where you where trying it, i can maybe take a look for you 😀

Thread Thread
 
krishnay2000 profile image
Krishnaraj Yadav • Edited

Sure . Here it is
github.com/krishna-y2000/Uploading...
Server file of above code is in /routes/uploadFiles.js and /routes/upload.js.
Client file is in /views/HomePage.ejs and /views/upload.ejs

Thread Thread
 
krishnay2000 profile image
Krishnaraj Yadav

Update in error :
Please refer this image because the comment box is not responding properly .
dev-to-uploads.s3.amazonaws.com/i/...
You can mail me if you want to text me in detail.
Email : krishnay.75676@gmail.com
Thanks alot for your effort.