How to upload a file and save into a mongodb document. In my form, i have two button 1. for upload a file and 2. for save the document. But am not sure about the flow here. Am using reactjs as my frontend. Please suggest.
Asked
Active
Viewed 1,000 times
1 Answers
0
MongoDb provides you the option to store images. MongoGridFS.
Study more about MongoGridFS
On click of a button, make a call to upload the image uploaded and save the image in the mongoDB.
You just need to send form data through ajax and take the save functionality in the back end

Viresh Mathad
- 576
- 1
- 5
- 19